Open Data

UK Legislation MCP Server

Chat with AI and run tools instantly.

Search and access the full text of UK legislation through the official legislation.gov.uk API. Covers all UK Public General Acts, Statutory Instruments, Scottish and Welsh legislation, and Northern Ireland legislation — both current ('revised') and historical ('as enacted') versions. Also provides legislative effects (amendments, repeals, substitutions) showing how laws change over time.

Managed
4 tools
Agent guide included

Chat with AI and run tools instantly.

Browse all tools

AI Skill
SKILL.md

Domain knowledge for UK Legislation — workflow patterns, data models, and gotchas for your AI agent.

UK Legislation (legislation.gov.uk)

The official UK legislation database, maintained by The National Archives. No auth required.

Key Concepts

  • Legislation types: ukpga (UK Public General Acts), uksi (UK Statutory Instruments), asp (Acts of Scottish Parliament), asc (Acts of Senedd Cymru), nia (Acts of NI Assembly). Combine with + for multi-type searches (e.g. ukpga+uksi).
  • Versions: Each piece of legislation has an as enacted version and a revised (current) version incorporating all amendments. Point-in-time versions show the law as it stood on a specific date.
  • Effects: Amendments, repeals, substitutions and other changes that one piece of legislation makes to another. Effects track whether they've been applied to the revised text.
  • Sections: Legislation is divided into Parts, Chapters, and Sections. Use type/year/number to identify an Act (e.g. ukpga/1996/18 = Employment Rights Act 1996).

Common Use Cases

  • Search by title keywords to find relevant legislation
  • Retrieve the full text of a specific Act or Statutory Instrument
  • Get a specific section (e.g. s.94 of Employment Rights Act 1996 on unfair dismissal)
  • Track what amendments have been made to a piece of legislation

Gotchas

  • Search returns Atom feed XML — the tools parse this into structured JSON for you.
  • Legislation content is returned as HTML — large Acts may produce very long responses. Use the section-level tool for targeted retrieval.
  • The API rate limit is 3,000 requests per 5 minutes per IP.
  • Not all legislation has revised versions — older Acts may only be available as enacted.

Tools in this Server (4)

Leg Get Document

Retrieve the full text of a specific UK Act, Statutory Instrument, or other legislation. Identified by type/year/number (e.g. ukpga/1996/18 = Employme...

Leg Get Section

Retrieve a specific section, part, or schedule from UK legislation. More targeted than the full document tool — use this for looking up specific provi...

Leg Search

Search UK legislation by title keywords, type, and year. Covers all UK Acts of Parliament, Statutory Instruments, Scottish/Welsh/NI legislation, and r...

Leg Search Effects

Search for legislative effects — amendments, repeals, substitutions, and other changes that one piece of legislation makes to another. Filter by affec...

Frequently Asked Questions

What is the UK Legislation MCP server?

Search and access the full text of UK legislation through the official legislation.gov.uk API. Covers all UK Public General Acts, Statutory Instruments, Scottish and Welsh legislation, and Northern Ireland legislation — both current ('revised') and historical ('as enacted') versions. Also provides legislative effects (amendments, repeals, substitutions) showing how laws change over time. It provides 4 tools that AI agents can use through the Model Context Protocol (MCP).

How do I connect UK Legislation to my AI agent?

Add the MCPBundles server URL to your MCP client configuration (Claude Desktop, Cursor, VS Code, etc.). The URL format is: https://mcp.mcpbundles.com/bundle/legislation-gov-uk. Authentication is handled automatically.

How many tools does UK Legislation provide?

UK Legislation provides 4 tools that can be called by AI agents, along with a SKILL.md that gives your AI agent domain knowledge about when and how to use them.

What authentication does UK Legislation require?

UK Legislation uses open data APIs — no authentication required.

Setup Instructions

Connect UK Legislation to any MCP client in minutes

https://mcp.mcpbundles.com/bundle/legislation-gov-uk

One-click install:

The link prefills the Add custom connector dialog — you still review the values and click Add, then Connect to complete OAuth.

Or add manually

  1. Open claude.ai → Settings → Connectors.
  2. Click the + button and choose Add custom connector.
  3. Set Name to UK Legislation and paste the MCP URL into Remote MCP server URL.
  4. Click Add. UK Legislation will appear under Not connected — select it and click Connect to complete OAuth.
Name: UK Legislation
Remote MCP server URL: https://mcp.mcpbundles.com/bundle/legislation-gov-uk
Authentication: OAuth

Custom connectors at claude.ai require a paid Claude plan (Pro, Max, Team, or Enterprise).

Try UK Legislation now

No API key or third-party login required. Chat with AI and run tools instantly.