Skip to main content

MCP server for GOV.UK — search, content, organisations and postcode lookup

Project description

govuk-mcp

PyPI Glama smithery badge Install in VS Code Install in VS Code Insiders Install in Cursor Install in VS Code (local)

MCP server for GOV.UK — search, content retrieval, organisation lookup, and postcode resolution.

Tools

Tool Description
govuk_search Full-text search across 700k+ GOV.UK pages, with format and organisation filters
govuk_get_content Page metadata and navigable section index for any GOV.UK page by base path
govuk_get_section Body HTML for a single named section (anchor) of a GOV.UK page
govuk_grep_content Regex/substring search within the body of a specific GOV.UK page
govuk_get_organisation Get details for a UK government organisation (type, parent, children, contacts)
govuk_list_organisations Paginated list of all government organisations registered on GOV.UK
govuk_lookup_postcode Resolve a UK postcode to local authority, region, constituency, and NHS board

All data is sourced from official public GOV.UK APIs and postcodes.io. No API keys required.

Resources

For protocol-aware clients (Claude, Cursor, Inspector), the server also exposes govuk:// resource templates:

URI Returns
govuk://content/{base_path*}/header Page metadata (title, doc type, dates)
govuk://content/{base_path*}/index Section anchor:heading list
govuk://content/{base_path*}/section/{anchor} Bounded HTML for one section
govuk://content/{base_path*}/details/{field} Schema-specific details field
govuk://content/{base_path*}/links/{rel} Related content by link type
govuk://organisation/{slug} Organisation profile

Connect

Hosted (no install)

{
  "mcpServers": {
    "govuk": {
      "type": "http",
      "url": "https://govuk-mcp.fly.dev/mcp"
    }
  }
}

Local (uvx)

{
  "mcpServers": {
    "govuk": {
      "type": "stdio",
      "command": "uvx",
      "args": ["govuk-mcp"]
    }
  }
}

APIs used

API Base URL Auth
GOV.UK Search https://www.gov.uk/api/search.json None
GOV.UK Content https://www.gov.uk/api/content{path} None
GOV.UK Organisations https://www.gov.uk/api/organisations None
postcodes.io https://api.postcodes.io None

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

govuk_mcp-0.3.0.tar.gz (151.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

govuk_mcp-0.3.0-py3-none-any.whl (18.1 kB view details)

Uploaded Python 3

File details

Details for the file govuk_mcp-0.3.0.tar.gz.

File metadata

  • Download URL: govuk_mcp-0.3.0.tar.gz
  • Upload date:
  • Size: 151.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for govuk_mcp-0.3.0.tar.gz
Algorithm Hash digest
SHA256 64f7a6860c29469bed493d53db33b9cc8ce5df156c7ed81fd964a87cfd99cdfa
MD5 ee7b15fafd6ac80fb19a33be8fc9e38e
BLAKE2b-256 aee93f6be0cd0c83db2a72a749b85ed1f05c4a2e10b126d2b9ea6131c6d9569d

See more details on using hashes here.

Provenance

The following attestation bundles were made for govuk_mcp-0.3.0.tar.gz:

Publisher: release.yml on paulieb89/govuk-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file govuk_mcp-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: govuk_mcp-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 18.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for govuk_mcp-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 dd2a93ed348da0dcd0e5c608361b1c0c40fef8497a9a44a89657013caca80c7e
MD5 81a0849d47c8b3f1c5b350dea564400e
BLAKE2b-256 1ffd6b7426e09bd762c0a66f17646b15fe835c0aeb32136dd9d3f0d319639666

See more details on using hashes here.

Provenance

The following attestation bundles were made for govuk_mcp-0.3.0-py3-none-any.whl:

Publisher: release.yml on paulieb89/govuk-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page