eur-lex-mcp-server — Claude Code MCP server for EU law
eur-lex-mcp-server — an MCP server that pulls EU legislation, CJEU case law, and treaties into your agent. Use it when a legal basis or court ruling needs to sit next to your code or analysis.
Apache-2.0 ★ 13 updated 2026-10-23
claude mcp add --transport http eur-lex-mcp-server https://eur-lex.caseyjhand.com/mcpWhat eur-lex-mcp-server does
The server connects an agent to EUR-Lex and CELLAR. It searches acts by type, date, EuroVoc concept, author institution and in-force status, and fetches the full text as HTML, Markdown or Formex4 XML. Citations resolve too: CELEX numbers, ELI URIs, ECLI and Official Journal references.
A relations tool walks the CELLAR graph — amendments, repeals, consolidations, legal bases, interpreting rulings, citations, transpositions. Raw read-only SPARQL SELECT is available against the CELLAR endpoint, and a EuroVoc browser resolves thesaurus terms to concept URIs. The package ships 7 tools, 2 resources and one prompt for comparative EU/US legal analysis.
The limits are real. Paging stops at row 10,000, content is capped at 100,000 characters per call, and a keyword with letters but no digit, like R(01), scans every CELEX and takes tens of seconds. Search covers English titles only; document bodies are not searched. To point at your own SPARQL endpoint, set CELLAR_SPARQL_ENDPOINT as an environment variable.
What it helps with
- find an in-force EU act by type and date
- pull a regulation's full text as Markdown
- trace which acts amend or repeal a directive
- resolve a CELEX number from a citation
- look up a EuroVoc term for search filters
Example prompts for the agent
- Find in-force directives about personal data protection
- Fetch
32016R0679as Markdown, only articles 1 and 5 - Which acts cite
Regulation (EU) 2016/679as their legal basis?
How to install eur-lex-mcp-server
1Platform CLI: remote server
claude mcp add --transport http eur-lex-mcp-server https://eur-lex.caseyjhand.com/mcp2Platform CLI
claude mcp add --env CELLAR_SPARQL_ENDPOINT=<CELLAR_SPARQL_ENDPOINT> --env EURLEX_CONTENT_BASE_URL=<EURLEX_CONTENT_BASE_URL> --env SPARQL_QUERY_TIMEOUT_MS=<SPARQL_QUERY_TIMEOUT_MS> --env MAX_SPARQL_RESULTS=<MAX_SPARQL_RESULTS> --env MCP_LOG_LEVEL=<MCP_LOG_LEVEL> --transport stdio eur-lex-mcp-server -- npx -y @cyanheads/eur-lex-mcp-serverReplace <…> with your own values. 6 more environment variables are in the server README
1Platform CLI: remote server
codex mcp add eur-lex-mcp-server --url https://eur-lex.caseyjhand.com/mcp2Platform CLI
codex mcp add eur-lex-mcp-server --env CELLAR_SPARQL_ENDPOINT=<CELLAR_SPARQL_ENDPOINT> --env EURLEX_CONTENT_BASE_URL=<EURLEX_CONTENT_BASE_URL> --env SPARQL_QUERY_TIMEOUT_MS=<SPARQL_QUERY_TIMEOUT_MS> --env MAX_SPARQL_RESULTS=<MAX_SPARQL_RESULTS> --env MCP_LOG_LEVEL=<MCP_LOG_LEVEL> -- npx -y @cyanheads/eur-lex-mcp-serverReplace <…> with your own values. 6 more environment variables are in the server README
Config file
{
"mcpServers": {
"eur-lex-mcp-server": {
"url": "https://eur-lex.caseyjhand.com/mcp"
}
}
}{
"mcpServers": {
"eur-lex-mcp-server": {
"command": "npx",
"args": [
"-y",
"@cyanheads/eur-lex-mcp-server"
],
"env": {
"CELLAR_SPARQL_ENDPOINT": "<CELLAR_SPARQL_ENDPOINT>",
"EURLEX_CONTENT_BASE_URL": "<EURLEX_CONTENT_BASE_URL>",
"SPARQL_QUERY_TIMEOUT_MS": "<SPARQL_QUERY_TIMEOUT_MS>",
"MAX_SPARQL_RESULTS": "<MAX_SPARQL_RESULTS>",
"MCP_LOG_LEVEL": "<MCP_LOG_LEVEL>"
}
}
}
}Replace <…> with your own values. 6 more environment variables are in the server README
Config file
{
"servers": {
"eur-lex-mcp-server": {
"type": "http",
"url": "https://eur-lex.caseyjhand.com/mcp"
}
}
}{
"servers": {
"eur-lex-mcp-server": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@cyanheads/eur-lex-mcp-server"
],
"env": {
"CELLAR_SPARQL_ENDPOINT": "<CELLAR_SPARQL_ENDPOINT>",
"EURLEX_CONTENT_BASE_URL": "<EURLEX_CONTENT_BASE_URL>",
"SPARQL_QUERY_TIMEOUT_MS": "<SPARQL_QUERY_TIMEOUT_MS>",
"MAX_SPARQL_RESULTS": "<MAX_SPARQL_RESULTS>",
"MCP_LOG_LEVEL": "<MCP_LOG_LEVEL>"
}
}
}
}Replace <…> with your own values. 6 more environment variables are in the server README
1Platform CLI: remote server
gemini mcp add -t http eur-lex-mcp-server https://eur-lex.caseyjhand.com/mcp2Platform CLI
gemini mcp add -e CELLAR_SPARQL_ENDPOINT=<CELLAR_SPARQL_ENDPOINT> -e EURLEX_CONTENT_BASE_URL=<EURLEX_CONTENT_BASE_URL> -e SPARQL_QUERY_TIMEOUT_MS=<SPARQL_QUERY_TIMEOUT_MS> -e MAX_SPARQL_RESULTS=<MAX_SPARQL_RESULTS> -e MCP_LOG_LEVEL=<MCP_LOG_LEVEL> eur-lex-mcp-server npx -y @cyanheads/eur-lex-mcp-serverReplace <…> with your own values. 6 more environment variables are in the server README
Step by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about eur-lex-mcp-server
How do I install eur-lex-mcp-server in Claude Code?
For the HTTP transport, run claude mcp add --transport http eur-lex-mcp-server https://eur-lex.caseyjhand.com/mcp. For a local install via npx: `claude mcp add --env CELLAR_SPARQL_ENDPOINT=<CELLAR_SPARQL_ENDPOINT> --env EURLEX_CONTENT_BASE_URL=<EURLEX_CONTENT_BASE_URL> --env SPARQL_QUERY_TIMEOUT_MS=<SPARQL_QUERY_TIMEOUT_MS> --env MAX_SPARQL_RESULTS=<MAX_SPARQL_RESULTS> --env MCP_LOG_LEVEL=<MCP_LOG_LEVEL> --transport stdio eur-lex-mcp-server -- npx -y @cyanheads/eur-lex-mcp-server`.
What does eur-lex-mcp-server do?
It searches EU legislation, CJEU case law and treaties, fetches full text, resolves citations to CELEX and traverses CELLAR relations — amendments, repeals, legal bases, citations. It can also run SPARQL SELECT against CELLAR and browse EuroVoc.
Why is a keyword search sometimes slow?
A keyword with letters but no digit, like R(01), scans every CELEX number and can take tens of seconds. Search matches English titles only; document bodies are not indexed.