Search Canadian case law, browse legislation, and check citations via the CanLII API.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent — or use 1-click editor setup below.
We haven't yet run this listing's install command through our automated sandbox check. This isn't a red flag — we're steadily working through the catalog.
💡 Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
A Model Context Protocol (MCP) server for searching Canadian legal information via the CanLII API. Search cases, browse legislation, and check citations — all from Claude Desktop or Claude Code.
api.canlii.orgPrerequisites: Node.js 18+ and a CanLII API key (free for research use).
Claude Desktop — add to your config (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
Restart Claude Desktop after saving.
Claude Code:
From source (for development):
Full-text keyword search across all of CanLII — cases, legislation, and commentary. This is the primary entry point for legal research.
List all available court and tribunal databases. Returns database IDs needed by other tools.
Key Ontario databases: onsc (Superior Court), onca (Court of Appeal), oncj (Court of Justice), csc-scc (Supreme Court of Canada).
Browse case law decisions from a specific court database, ordered by most recently added. Supports date filters.
Get full details for a specific case — citation, decision date, docket number, keywords, and CanLII URL for reading the full decision.
Look up citation relationships for a case. Use citingCases to check if a case is still good law.
Quick citation preview returning max 5 results. Faster than the full citator for a quick check.
List all legislation databases. Ontario: ons (Statutes), onr (Regulations). Federal: cas (Statutes), car (Regulations).
List legislation items within a specific database.
Get metadata for a specific statute or regulation, including its CanLII URL.
search({ query: "gatekeeping parenting time" }) to find relevant casesget_case_metadata(...) to get the full citation and CanLII URLget_case_citator(..., metadataType: "citingCases") to verify the case is still good lawPer CanLII's API terms:
The server enforces these limits automatically with a built-in rate limiter.
Contributions are welcome! This project aims to make Canadian legal research more accessible through AI tooling.
Ways to contribute:
To submit a PR:
git checkout -b feature/my-improvement)npm run build && CANLII_API_KEY=your_key npm run start)If you find issues with the CanLII API responses, schema mismatches, or have ideas for new tools that would help legal researchers, please open an issue — even if you're not sure how to fix it. We'll investigate together.
This server is designed to be transparent and minimal:
api.canlii.org — no other network calls, no telemetry, no analyticschild_process, exec, or spawn@modelcontextprotocol/sdk (official Anthropic MCP SDK) and zod (schema validation)If you discover a security issue, please see SECURITY.md.
get_case_metadata separately for each case to get keywords, topics, decision date, and the CanLII URL.get_case_citator (full version) for comprehensive citation analysis.MIT — see LICENSE.
No reviews yet — be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/canlii)<a href="https://allmcps.com/mcp/canlii"><img src="https://allmcps.com/api/badge/canlii?style=directory" alt="Canlii on AllMCPs" /></a>