MCP ServerSSEOfficialv1.0.0

Swiss Case Law MCP Server

Search 971k Swiss court decisions, 21k laws, and 8M citation links via natural-language queries in Claude, ChatGPT, or Gemini. Built for legal researchers, developers, and law students who need free, open access to the complete Swiss legal system.

ch.opencaselaw/swiss-caselaw

Hosted URL

https://mcp.opencaselaw.ch

Transport

SSE

Auth

No auth required

Swiss Case Law repository at a glance

Live signal from GitHub, refreshed weekly.

Stars

36

Last commit

May 19, 2026

License

MIT

Language

Python

What the Swiss Case Law MCP server does

How models use it and what it is built for.

Search 971k Swiss court decisions, 21k laws, and 8M citation links via natural-language queries in Claude, ChatGPT, or Gemini. Built for legal researchers, developers, and law students who need free, open access to the complete Swiss legal system.

Connect to Swiss Case Law

Hosted endpoint — paste into any MCP client.

https://mcp.opencaselaw.ch

Resources

Where to find authoritative docs and source for Swiss Case Law.

Example prompts for Swiss Case Law

Paste any of these into Agent Studio after connecting Swiss Case Law.

  • Find leading cases on employment termination during probation period
  • Show me the citation graph for BGE 140 III 86 and its most influential descendants
  • Search federal and cantonal laws about parental leave across all three languages
  • Get the legislative history and Botschaft for Article 197 of the Swiss Civil Code

Documentation from project README

View on GitHub

Excerpted from the project's README — boilerplate sections (license, changelog, contributing) omitted for clarity.

Swiss Case Law Open Dataset

The complete machine-readable archive of Swiss case law and legislation — built for humans, designed for AI agents.

971,000+ court decisions · 5,516 federal laws · 15,722 cantonal laws · 8.09 M resolved citation edges · 11.26 M statute references · 83,958 Botschaft amendment references (459 verbatim Botschaften ingested, scaling)

Spans 1875 to today, covers every Swiss federal court and all 26 cantonal court systems (plus regulators: FINMA, ComCo, FDPIC, IndepBC, ElCom, PostCom, ComCom), mirrors federal legislation directly from Fedlex SPARQL and cantonal legislation by direct portal scraping for all 26 cantons (LexWork: 18 cantons; SIL: NE + JU; ZH OpenData; TI RL — the same publishing systems the cantons operate themselves) with LexFind PDF as fallback supplementing 4 cantons for laws missing from their primary portals and as the discovery catalog for 33,000+ legislative texts. Includes 83,958 Botschaft amendment references across 9,139 BBl publications, a Phase 2 verbatim Botschaft corpus (459 documents, 76K FTS5-indexed paragraphs as of 2026-05-11, scaling toward ~25K via Fedlex SPARQL discovery), per-article Botschaft digests for BV/BGFA, parliamentary debate transcripts for the Bundesverfassung, a resolved citation graph, and 35 MCP tools (33 remote in public mode + 2 local-only) usable from Claude, ChatGPT, Cursor, Gemini, Grok, or any MCP/function-calling client. CC0 public-domain data, MIT-licensed code, no sign-up, no API keys, no paywall.

CI Dashboard HuggingFace Data License: CC0--1.0 Code License: MIT


Why this exists

Swiss legal research today is fragmented across paywalls, inaccessible to language models, and prohibitively expensive for the people who need it most — law students, independent researchers, and anyone outside the major firms. Commercial databases (Weblaw, Swisslex, Legalis) charge hundreds of francs per month and still don't expose a clean API. LLMs hallucinate statute text because they have no authoritative source. Small cantons publish decisions in PDF archives nobody indexes.

OpenCaseLaw fixes this. Every published Swiss court decision, every federal and cantonal law, the resolved citation graph between them, and 35 MCP tools (33 remote in public mode + 2 local-only) that let any modern LLM act as a Swiss legal research assistant — all free, all open, all refreshed automatically.

What you get

Case law — 971,700+ decisions from 1875 to today across 108 courts, full text + structured metadata, covering:

  • All 7 federal courts (BGer, BVGer, BStGer, BPatGer, BGE, BGE historical, BGE-EGMR)
  • Federal military court (Militärkassationsgericht / MKG, 1,244 decisions 1915–2025)
  • All 26 cantonal court systems (first, second, and third instance)
  • Regulatory decisions (FINMA, ComCo, FDPIC, IndepBC, ElCom, PostCom, ComCom)
  • ECHR/EGMR: 834 Swiss-respondent (HUDOC) + general ECtHR Grand Chamber/Chamber/Committee (1,421 judgments live, full-corpus backfill in progress)
  • Three official languages: German 449,758 (46.3%), French 441,257 (45.4%), Italian 80,717 (8.3%); schema reserves rm for Romansh
  • Deduplicated via docket normalisation + content-length-aware merge
  • Updated daily; BGer decisions available within ~15 minutes of court publication

Legislation — every Swiss law, federal and cantonal, locally mirrored with article-level indexing:

  • 5,516 federal laws / ~133,468 articles in each of DE/FR/IT from the Fedlex SPARQL endpoint
  • 15,722 cantonal laws / 353,437 articles, direct-scraped from all 26 cantons (LexWork covers 18, SIL covers 2, ZH OpenData covers ZH, TI~RL covers TI); LexFind PDF fallback supplements 4 cantons for laws missing from their primary portals
  • Unified SQLite FTS5 search federates both corpora; sub-millisecond article lookup
  • Monthly refresh on the 2nd of each month (the day after laws enter into force)
  • 11.26 M resolved links from decisions to individual statute articles

Citation graph — the only public large-scale citation graph of the Swiss legal system:

  • 8.09 M resolved decision-to-decision citation edges with confidence scores
  • 11.26 M decision-to-statute links resolved against the current consolidated text
  • Bidirectional lookup, appeal-chain resolution (Instanzenzug), leading-case ranking by citation authority
  • Powers find_leading_cases, find_citations, find_appeal_chain, analyze_legal_trend (top: BGE 125 V 351 with 85,108 incoming citations)

35 MCP tools (33 remote in public mode + 2 local-only) — specialised research tools that run in your LLM of choice:

  • Natural-language decision search (BM25 + synonym expansion + Haiku reranking, MRR@10 = 0.647 on a 100-query golden set)
  • Leading-case discovery, citation networks, appeal chains, jurisprudence evolution
  • Federal + cantonal law article lookup, full-text search across both — with colloquial→legal vocabulary expansion (searching "Vaterschaftsurlaub" finds the statute even though it says "Urlaub des andern Elternteils") and cross-language cantonal search (German query finds French/Italian cantonal laws)
  • Doctrine overviews (statute + authority-ranked BGEs + timeline + Botschaft reference)
  • Legislative history (Materialien) — 83,958 Botschaft amendment references across 9,139 BBl publications and 33,465 distinct (statute, article) pairs; Phase 2 verbatim Botschaft corpus (459 documents, 76K FTS5-indexed paragraphs as of 2026-05-11) accessible via search_botschaft (topical FTS5 across the verbatim corpus), get_article_purpose (verbatim Botschaft text for a specific article), and get_article_history (chronological timeline composing statute + Botschaft + leading cases + commentary); per-article digests (legislative intent, key arguments, design choices, rejected alternatives) for BV and BGFA; parliamentary debate transcripts for the BV. Full verbatim ingest to ~25K Botschaften via Fedlex SPARQL discovery is scaling.
  • Decision-structure accessget_decision_structure (Sachverhalt + Erwägungen + Dispositiv + Regeste split), get_erwaegung (verbatim Schweizer-citation Einheit, e.g. get_erwaegung("BGE 140 III 86", "2.3")), get_regeste (official BGer/BVGer/BStGer head-note)
  • Scholarly commentary lookup from OnlineKommentar.ch + OpenLegalCommentary.ch (1,058 commentaries)
  • Fallbearbeitung exam questions generated from real BGE fact patterns, with hidden analysis for practice
  • Draft mock decisions from fact patterns (research-only tool for grounding LLM outputs)
  • Structured case briefs (regeste, Sachverhalt, Erwägungen, Dispositiv, cited statutes, authority)

Multiple access paths — same data, two distinct audiences:

For LLM users, researchers and developers — full 24-tool surface:

  • Remote MCP server at mcp.opencaselaw.ch (SSE + Streamable HTTP) — 30-second setup in any MCP client (Claude, ChatGPT, Cursor, Gemini, Windsurf)
  • OpenAI-compatible tool definitions for Grok/xAI and any function-calling LLM API
  • Local MCP server — full offline capability, 35 tools (33 remote in public mode + 2 local-only), ~65 GB disk
  • 30-route REST API with interactive documentation (Swagger UI + OpenAPI spec)
  • Bulk Parquet download via the HuggingFace dataset (~7 GB)
  • Live dashboard + browsing UI at opencaselaw.ch

For legal practitioners drafting documents — curated practitioner surface:

  • Word add-in — Search decisions and insert correctly-formatted Swiss legal citations directly in Word (no copy-paste). Click an Erwägung to insert it with the correct sub-citation; click a law § to insert that alinea. Free Audit scans the whole document for fabricated citations and bad pinpoints (deterministic, no LLM). Pro tier (Stripe-billed, CHF 5/month, 25 AI calls/day shared, structural PII redaction) adds four AI tools: Verify (single citation vs. full-text decision), Strengthen (paragraph x-ray with leading-case suggestions ranked by citation-graph centrality + commentary excerpts), Find Support (locate decisions that back an unsupported statement, scored 0–100), and Reflect (literary mirror on the whole document — one canonical work that frames the same human dilemma + one reflective question). Exposes ~8 of the 35 MCP tools (33 remote in public mode + 2 local-only) through the REST API, tuned for the write-your-brief workflow.

Performance you can defend in a paper:

Metric Value
Decision search quality MRR@10 = 0.647 (online) / 0.470 (offline reproducible) · +102 % over baseline
Article lookup latency < 1 ms (local FTS5)
BGer publication → searchable ~15 min (was 24 h pre-poller)
Daily full-text rebuild ~5 h, zero downtime (atomic swap)
Citation-to-decision resolution 8.09 M edges resolved (post-build 2026-05-11)

Continue reading on GitHub

Swiss Case Law MCP server — FAQ

Common questions about connecting and running Swiss Case Law.

  • What data does this MCP server cover?

    971,700+ Swiss court decisions (1875–today) from 108 courts including all federal courts and all 26 cantonal systems, plus 5,516 federal laws and 15,722 cantonal laws in German/French/Italian. It also includes 8.09M resolved citation edges and 83,958 Botschaft amendment references.

  • Do I need an API key or sign-up?

    No. The remote MCP server at `mcp.opencaselaw.ch` is completely free with no authentication required. All data is CC0 public domain and the code is MIT-licensed.

  • How current is the data?

    BGer decisions are searchable within ~15 minutes of court publication. The full corpus is updated daily, and legislation is refreshed monthly on the 2nd of each month.

  • Can I use this offline?

    Yes. You can run a local MCP server with all 35 tools and ~65 GB of data, or download bulk Parquet files (~7 GB) from HuggingFace for offline analysis.

  • How does the search quality compare to commercial legal databases?

    The natural-language search achieves MRR@10 = 0.647 on a 100-query golden set, with 102% improvement over baseline. It uses BM25 + synonym expansion + Haiku reranking, and includes colloquial-to-legal vocabulary mapping (e.g., 'Vaterschaftsurlaub' finds 'Urlaub des andern Elternteils').

Run Swiss Case Law across 60+ AI models, side-by-side

Connect Swiss Case Law to Claude, GPT, Gemini, DeepSeek and 60+ AI models in MCP Agent Studio. Compare answers side-by-side, save reusable agent presets, share runs — all in your browser, no install required.

Open Agent Studio

Related servers

More on MCP Playground