Canadian Legal Data

Open Access to Canadian Law

Free, open access to 180,000+ Canadian court decisions and 5,700+ federal laws and regulations — for researchers, developers, lawyers, and anyone interested in Canadian law.

Coverage

Federal Courts

  • Supreme Court of Canada 11,000 · 1877–present
  • Federal Court of Appeal 8,000 · 2001–present
  • Federal Court 34,000 · 2001–present
  • Tax Court of Canada 8,000 · 2003–present
  • Court Martial Appeal Court <1,000 · 2001–present

Provincial Courts

  • BC Court of Appeal 14,000 · 1999–present
  • BC Supreme Court 50,000 · 2000–present
  • Ontario Court of Appeal 17,000 · 2007–present
  • Yukon Court of Appeal <1,000 · 2000–present

Tribunals

  • IRB — Refugee Appeal Division sample 14,000 · 2013–present
  • IRB — Refugee Protection Division sample 7,000 · 2002–2020
  • Refugee Law Lab Reporter (RPD) sample 1,000 · 2019–present
  • Social Security Tribunal 17,000 · 2013–present
  • Canadian Human Rights Tribunal 1,000 · 2003–present

Legislation

  • Federal Statutes 1870–present
  • Federal Regulations 1945–present

Four Ways to Access

Choose the integration method that fits your workflow.

Model Context Protocol (MCP) lets AI assistants like Claude and ChatGPT query our entire database in plain language. Connect once, then ask anything about Canadian law.

Setup for Claude

In claude.ai: click SettingsConnectorsAdd Custom ConnectorName: a2aj → MCP Server URL:

https://mcp.a2aj.ca/mcp

Start a new chat and ask anything about Canadian law.

MCP Setup Guide →

Search and retrieve specific documents programmatically. No API key required. Supports full-text and name search with advanced operators (Boolean, phrases, wildcards, proximity), date and dataset filters, and bilingual results.

Key Endpoints

  • /search — Full-text and name search across cases and laws, with filters for date, dataset, and language
  • /fetch — Retrieve a specific document by citation (e.g. 2023 SCC 17 or RSC 1985, c C-46)
  • /coverage — List available datasets with document counts and date ranges

Quick Start

$ pip install requests pandas import requests, pandas as pd # Search case law response = requests.get("https://api.a2aj.ca/search", params={ "query": "right to housing", "doc_type": "cases", "size": 10 }) df = pd.DataFrame(response.json()["results"]) # Fetch a specific case by citation response = requests.get("https://api.a2aj.ca/fetch", params={ "citation": "2023 SCC 17", "doc_type": "cases" })

Response Fields

{ "results": [{ "dataset": "SCC", "citation_en": "2023 SCC 17", "citation2_en": "", "name_en": "Canadian Council for Refugees v. Canada ...", "document_date_en": "2023-06-16T00:00:00", "url_en": "https://decisions.scc-csc.ca/...", "unofficial_text_en": "...", "upstream_license": "See upstream license ..." }, ...] }

See the full field reference for all columns.

Interactive API Docs → Code Examples →

Access 191,000+ case law decisions and 5,700+ federal laws and regulations through HuggingFace. Ideal for training language models, large-scale empirical analysis, or working with data in Python. Supports streaming for memory-efficient loading.

Quick Start

$ pip install datasets pandas from datasets import load_dataset # Load all case law (or filter by court: data_dir="SCC") cases = load_dataset("a2aj/canadian-case-law", split="train") # Load all federal laws (or filter: data_dir="LEGISLATION-FED") laws = load_dataset("a2aj/canadian-laws", split="train") df = cases.to_pandas()

Returns the same fields as the API: dataset, citation_en, name_en, document_date_en, unofficial_text_en, and bilingual equivalents. See the full field reference.

Case Law Dataset → Laws Dataset → Code Examples →

Download datasets directly as Parquet files — an efficient columnar storage format that works with pandas, Polars, and most data analysis tools. No API keys or special libraries required beyond pandas.

Quick Start

$ pip install pandas import pandas as pd # Load a specific court (e.g. Supreme Court of Canada) url = "https://huggingface.co/datasets/a2aj/canadian-case-law/resolve/main/SCC/train.parquet" df = pd.read_parquet(url) # Load federal legislation url = "https://huggingface.co/datasets/a2aj/canadian-laws/resolve/main/LEGISLATION-FED/train.parquet" df = pd.read_parquet(url)

Download Instructions & Examples →

Notes on Data

Data Quality & Freshness

Datasets are updated weekly. All texts are unofficial copies collected through automated processes. While we make best efforts, these automated processes inevitably produce some inaccuracies and incompleteness. Always verify critical information against official sources. Each document includes a link to its original source or instructions about how to obtain the original document.

Privacy Considerations

Court decisions are public documents but may contain sensitive personal information. Users must comply with applicable privacy laws and respect publication bans. We encourage responsible use that considers the impact on affected communities.

Licensing

Our code and data collection methods are open source under the MIT license. Individual documents retain the original licensing terms through which we obtained them (if any), which are included with each document. We're actively working to expand access while respecting legal requirements.

Non-Affiliation

This project is not affiliated with the Government of Canada, the Department of Justice, or any of the courts or tribunals from which we have gathered data.

Citation

If you use this dataset in your research or projects, please cite:

Sean Rehaag & Simon Wallace, "A2AJ Canadian Legal Data" (2025), online: GitHub https://github.com/a2aj-ca/canadian-legal-data

Contact & Support

About the Project

The Canadian Legal Data project is maintained by Access to Algorithmic Justice (A2AJ), a research initiative co-hosted by York University's Osgoode Hall Law School and Toronto Metropolitan University's Lincoln Alexander School of Law.

This work is supported by funding from the Law Foundation of Ontario and the Social Sciences and Humanities Research Council of Canada, with computational resources from the Digital Research Alliance of Canada.