UK Government Technology Standards MCP Server
Provides AI assistants with access to 102 curated UK Government technology standards, enabling context-aware recommendations for accessibility, APIs, security, cloud strategy, and more.
README
UK Government Technology Standards MCP Server
A Model Context Protocol (MCP) server providing access to 102 curated UK Government technology standards for AI assistants. Get context-aware recommendations for accessibility, APIs, security, cloud strategy, and more.
What This Provides
- 102 Curated Standards: Carefully selected UK Government tech standards URLs
- Context-Aware Recommendations: Get standards based on your work type and project phase
- Hybrid Search: Combines exact keyword matching with semantic understanding
- Multiple Access Methods: MCP protocol, HTTP API, and command-line tools
- Real-time Updates: Keep standards current with automated refresh capabilities
Quick Start
Prerequisites
- Node.js 18+
- npm (comes with Node.js)
Installation
# Clone the repository
git clone <repository-url>
cd uk-gov-tech-standards-mcp
# Install dependencies
npm install
# Build the project
npm run build
# Setup database with curated standards (takes 2-3 minutes)
npm run setup
Usage
Start MCP Server:
npm run serve
Start HTTP API Server:
npm run serve:http
# API available at http://localhost:3001
Docker Deployment
Prerequisites
- Docker and Docker Compose
Quick Start with Docker
# Clone the repository
git clone <repository-url>
cd uk-gov-tech-standards-mcp
# Copy environment template
cp docker.env.template .env
# Build and start services
docker-compose up -d
# Check status
docker-compose ps
The setup includes:
- MCP Server:
localhost:3000 - HTTP API:
localhost:8080 - ChromaDB:
localhost:8000(vector database)
Docker Services
MCP Server (default):
docker-compose up -d uk-gov-standards-mcp
HTTP Server (alternative):
docker-compose --profile http-only up -d
Both servers:
docker-compose up -d uk-gov-standards-mcp uk-gov-standards-http
Data Persistence
Docker volumes persist data in:
./data/- SQLite database./logs/- Application logs./models/- ML models cachechromadb_data- Vector embeddings
Docker Configuration
Environment Variables (.env file):
NODE_ENV=production
LOG_LEVEL=info
DB_PATH=/app/data/standards.db
CHROMA_HOST=chromadb
CHROMA_PORT=8000
Health Checks:
# Check MCP server health
curl http://localhost:3000/health
# Check HTTP API health
curl http://localhost:8080/health
# Check ChromaDB health
curl http://localhost:8000/api/v1/heartbeat
Logs:
# View all logs
docker-compose logs -f
# View specific service logs
docker-compose logs -f uk-gov-standards-mcp
docker-compose logs -f chromadb
MCP Client Configuration
Claude Desktop
Add to your claude_desktop_config.json:
{
"mcpServers": {
"uk-gov-standards": {
"command": "node",
"args": ["/absolute/path/to/uk-gov-tech-standards-mcp/dist/index.js"],
"env": {
"DATABASE_URL": "sqlite:/absolute/path/to/uk-gov-tech-standards-mcp/standards.db",
"NODE_ENV": "production",
"LOG_LEVEL": "info"
}
}
}
}
Other MCP Clients
The server implements the full MCP specification. Use these connection details:
- Command:
node - Args:
["/path/to/dist/index.js"] - Working Directory: Project root
- Environment: Set
DATABASE_URLto your database path
🛠 MCP Tools
The server provides 8 context-aware tools:
Core Search Tools
search_uk_gov_standards
- Search across all 102 curated standards
- Hybrid search: exact keywords + semantic understanding
- Parameters:
query(required),category,organisation
get_standard_by_id
- Get detailed information about a specific standard
- Parameters:
standardId(required)
list_categories
- Get all available categories with counts
- No parameters required
get_recent_updates
- Get recently updated standards
- Parameters:
daysBack(default: 30)
Context-Aware Tools
get_applicable_standards
- Get standards for specific work context
- Parameters:
workType[],serviceType[],developmentPhase[]
get_mandatory_standards
- Get all mandatory/critical standards
- No parameters required
get_standards_by_priority
- Filter by priority level
- Parameters:
priority(critical, high, medium, low)
get_category_hierarchy
- Get hierarchical category structure
- Parameters:
categoryId(optional)
Compliance Tool
check_compliance
- Generate compliance checklist for your service
- Parameters:
serviceDescription(required)
HTTP API
When running npm run serve:http, access these endpoints:
Search & Discovery
GET /api/search?q=<query>&category=<category>&org=<organisation>
GET /api/standards/<id>
GET /api/categories
GET /api/recent?days=<days>
Context-Aware Endpoints
POST /api/applicable
{
"workType": ["frontend", "backend"],
"serviceType": ["citizen-facing"],
"developmentPhase": ["development", "testing"]
}
GET /api/mandatory
GET /api/priority/<level>
GET /api/hierarchy?categoryId=<id>
POST /api/compliance
{
"serviceDescription": "Description of your service"
}
Curated Standards Categories
102 standards across 11 focused categories:
| Category | Count | When to Use |
|---|---|---|
| Design and Build Government Services | 30 | Any government service development |
| Standards | 21 | General compliance and best practices |
| Secure By Design | 14 | Security-focused development |
| Accessibility | 10 | Frontend/UI development |
| Open source and open standards | 8 | Technology selection and architecture |
| APIs | 5 | REST, SOAP, GraphQL development |
| Legacy Technologies | 3 | Modernization projects |
| Native or Hybrid Apps | 3 | Mobile app development |
| Cloud Strategy | 2 | Cloud adoption and migration |
| Data | 2 | Data management and GDPR |
| Application Development | 1 | General development guidance |
🔍 Search Capabilities
Hybrid Search System
- FTS Search: Fast exact/partial keyword matching
- Semantic Search: Understanding meaning and context (when available)
- Graceful Fallback: Works even if semantic features unavailable
Context-Aware Recommendations
Get relevant standards based on your specific work:
| Work Context | Example Results |
|---|---|
| Frontend + Citizen-facing | Accessibility standards, WCAG guidelines |
| Backend + APIs | API technical standards, security guidelines |
| Mobile + Native apps | iOS/Android security, app store guidelines |
| Cloud + Data | GDPR compliance, cloud-first policy |
Advanced Usage
Custom Database Path
DATABASE_URL="sqlite:/custom/path/standards.db" npm run setup
Update Existing Database
npm run update # Refresh standards content
Development Mode
npm run dev # Run with hot reload
npm test # Run test suite
Logging Configuration
Set LOG_LEVEL environment variable:
error: Errors onlywarn: Warnings and errorsinfo: General information (default)debug: Detailed debugging
System Architecture
Focused Approach
This system uses a curated approach rather than broad discovery:
- ✅ 102 specific URLs from carefully selected UK Government standards
- ✅ 11 focused categories with clear applicability context
- ✅ Context-aware recommendations based on your work context
- ✅ Priority-based filtering (critical, high, medium, low)
- ✅ Mandatory vs. optional clearly identified
- ✅ Faster, predictable setup (2-3 minutes vs 10+ minutes)
Technology Stack
- Database: SQLite with FTS5 full-text search
- Search: Hybrid FTS + semantic similarity (optional)
- Web Scraping: Puppeteer with intelligent content processing
- API: Express.js HTTP server
- MCP: Full Model Context Protocol implementation
- Embeddings: Transformers.js with local models (optional)
Data Sources
All 102 standards are sourced from official UK Government websites:
- GDS Service Manual: Design and accessibility standards
- NCSC Guidance: Security and cyber security standards
- Cabinet Office: Digital service and open standards
- Gov.UK Guidance: APIs, cloud, and technical standards
- ICO Resources: Data protection and GDPR compliance
Troubleshooting
Common Issues
Database corruption:
rm -f standards.db*
npm run setup
Port already in use:
# Change port in src/http-server.ts or kill existing process
pkill -f "http-server"
Semantic search unavailable:
- This is normal - the system gracefully falls back to FTS search
- Full semantic search requires additional vector database setup
Getting Help
- Check the logs in
logs/server.log - Verify Node.js version:
node --version(requires 18+) - Ensure database exists:
ls -la standards.db - Test basic functionality:
npm test
##� License
MIT License - see LICENSE file for details.
Contributing
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
Updates
The system automatically tracks when standards are updated. Run npm run update periodically to refresh content.
Built for AI assistants to provide accurate, up-to-date UK Government technology guidance.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.