Global Law MCP

Git for Global Law

Global Law stores different countries' laws as git history and gives an agent an MCP with 18 tools for reading the law on any date.

  • 1,967 ★ on the repository
  • Last commit
MCP server

Minimal access

Why this level

  • The server runs locally and only reads cloned law texts, with no network calls and no access to secrets.
All reasons and checks

lexifina/global-law

Install

Manual install

git clone --depth 1 https://github.com/lexifina/global-law && cd global-law

The clone carries ready MCP setup for Claude Code, Cursor, VS Code and Codex; the server starts when the folder opens.

Access and checks

How we review

Minimal accessThe tool runs nothing and makes no network calls.

  • The server runs locally and only reads cloned law texts, with no network calls and no access to secrets.

This is third-party code. Review the repository files before installing.

What it does

Global Law keeps each jurisdiction's law in a separate `lexifina/<country>-law` repository, where every commit is one law provision taking effect, written by that very provision. The main repository collects these jurisdictions as submodules, arranged by country, state and city, and advances each to its latest commit; the `In-force` date on every commit gives the law of any country on any date. `tools/mcp_server.py` is a Model Context Protocol server with 18 read-only tools: find a provision, read it on a date, see who wrote each word, compare dates, view a provision's history, search the text and its changes, and check a case or a brief against the law currently in force. The server needs only Python 3.9+ and git, runs on the user's own machine and makes no network calls.

Who it is for. Lawyers and legal researchers who need the exact text of a law on a specific date, with who wrote every word tracked.

Good fit when

  • The text of a specific law provision on a given date is needed, not its current version.
  • An agent needs to check a case or brief against the law as it stood in force at that time.
  • A provision's full change history is needed, with which law made each edit.
  • Comparing the same provision's text on two different dates needs to be exact, not from the model's memory.

Not a fit when

  • The needed jurisdiction has no separate `lexifina/<country>-law` repository yet.
  • Current case law and interpretations matter, not just the statute's own text.
  • A full country clone takes several gigabytes, and a shallow partial clone does not fit the task.

Example request

What did 11 U.S.C. §1182(1) say on 1 May 2022, and which law last changed it?

MCP

Transport
stdio
Authentication
not required

Limitations

A full clone of one country takes several gigabytes; `--depth 1` downloads only the index with no history, but reading dates needs a jurisdiction's whole history, so a country repository cannot be cloned with `--depth`, only the main repository can. The tools give only the law's text and its history, not case law, interpretations or legal commentary. Each jurisdiction's legal text is distributed under that repository's own terms, though the main repository and tools themselves are CC0. The MCP server runs locally with no network calls, but first downloading a needed country still requires internet access to clone its submodule.

How to disable. Remove the `global-law` entry from your client's `mcpServers` configuration and delete the cloned repository entirely.

FAQ

How do I connect the MCP for another client?

Add to your `mcpServers` configuration: `git -C /path/to/global-law -c alias.global-law-mcp=!sh tools/mcp.sh global-law-mcp`.

Does the MCP server need internet access?

The server itself does not, making zero network calls; internet is only needed to clone a country the first time.

How do I clone a country without its whole history?

A country cannot be cloned with `--depth`, since the tools read dates from its whole history; `--filter=blob:none` gives the index without file contents.

How many tools does the MCP server provide?

18 read-only tools: finding a provision, reading it on a date, word authorship, date comparison, history, text and change search, checking a case against the law.

Can the law text be used in my own product?

The main repository and tools are CC0, no permission or credit needed; each country's law text is distributed under that repository's own terms.

Discussion

No questions or reviews yet.

An MCP server for Korea's official legal database: search statutes, case law and ordinances, and verify article citations against fabrications

MCP serverExtended access2.9KRepository stars

A self-hosted MCP server for Korean law: 18 tools for statute articles, case law and contract review.

MCP serverMinimal access133Repository stars
Russian stack

An MCP server with a database of Russian federal laws and codes: full-text article search, citation checks and currency checks

MCP serverExtended access9Repository stars

A free MCP server for Taiwan law: the agent finds court judgments and statute articles and cites them with checkable links

MCP serverExtended access346Repository stars

A modular set of 32 legal skills for Polish law that enforces online verification of every provision and case signature.

SkillBroad access315Repository stars

Overleaf MCP Server: LaTeX projects over Git

Overleaf MCP Server (YounesBensafia)

An agent reads and edits Overleaf project files through standard Git sync and pushes the changes to the project itself

MCP serverBroad access66Repository stars

README in short

The project started as a breakdown of only the US Code and reached first place on Hacker News on 28 October, after which it expanded to cover law worldwide.

README badge

Report a problem