The Canadian Building Code MCP Server enables AI assistants to search, navigate, and cite over 24,000 sections across 15+ Canadian building codes (NBC, OBC, BCBC, ABC, QCC, and more) through an MCP-compatible interface.
Core Capabilities:
Search building codes - Find relevant sections using keywords with fuzzy matching, synonym support, and TF-IDF search across all codes
Retrieve section details - Access specific section content, citations, page numbers, and coordinates by section ID (e.g., 9.10.14.1)
Navigate code hierarchy - Explore parent, child, and sibling relationships between sections
Verify sections - Confirm section IDs exist and retrieve formal citations to prevent AI hallucination
Determine applicable codes - Identify which building codes apply to specific Canadian cities, provinces, or territories
List available codes - View all supported codes and their connection status
Connect personal PDFs (BYOD mode) - Set up local PDF paths for full text extraction instead of just coordinates, ensuring copyright compliance
Extract table content - Convert code tables to markdown format
Access via REST API - Use the hosted API for searches without local setup
Key Benefits:
Token-optimized responses (81% reduction compared to naive approaches)
Compatible with MCP clients like Claude Desktop and Cursor
Enables accurate answers about building requirements, compliance documentation, and code navigation across Canadian jurisdictions
Click on "Install Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Canadian Building Code MCP ServerFind fire separation requirements for garages in the NBC"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Canadian Building Code MCP
AI-powered search for 24,000+ Canadian building code sections.
Enable AI assistants to search, navigate, and cite building regulations across NBC, OBC, BCBC, and 13 other Canadian codes.
Works with Claude Desktop and any MCP-compatible client (Cursor, Windsurf, etc.)
Why This Exists
Architects and engineers waste hours searching through thousands of pages of building codes. This MCP server lets AI do the heavy lifting:
Features
Feature | Description |
24,000+ Sections | NBC, OBC, BCBC, ABC, QCC + 11 more codes indexed |
Smart Search | Fuzzy matching, synonyms, "Did you mean?" suggestions |
Token Optimized | 81% reduction vs naive approach (v1.2.0) |
Copyright Safe | BYOD model - coordinates only, you provide the PDF |
Jurisdiction Aware | Knows which code applies where (ON→OBC, BC→BCBC) |
Architecture
Two Modes:
Map-Only (default): Returns page numbers & coordinates. No PDF needed.
BYOD: Connect your PDF via
set_pdf_pathfor full text extraction.
Quick Start (1 minute)
Option 1: uvx (Recommended)
Add to claude_desktop_config.json:
Option 2: pip
Example Conversations
Finding Requirements
Checking Specific Sections
Jurisdiction Lookup
Supported Codes
National Codes (4)
NBC 2025, NFC 2025, NPC 2025, NECB 2025
Provincial Codes (9)
Ontario: OBC 2024 (Vol 1 & 2), OFC
British Columbia: BCBC 2024
Alberta: ABC 2023
Quebec: QCC, QECB, QPC, QSC (2020)
User's Guides (3)
IUGP9 (Part 9 Housing), UGP4 (Structural), UGNECB (Energy)
Total: 24,000+ indexed sections
Token Efficiency (v1.2.0)
Built-in optimizations reduce token usage:
Optimization | Reduction |
| 81% |
| 61% |
Default | ~50% |
Best practice: Use limit=5-10 and only request verbose=true when needed.
See Token Efficiency Guide for details.
Tools Available
Tool | Purpose |
| Show available codes and connection status |
| Find sections by keywords |
| Get section details (page, citation, text) |
| Get table content as markdown |
| Navigate parent/child sections |
| Check if section ID exists |
| Find codes for a location |
| Connect PDF for text extraction |
API Access
REST API: https://canada-aec-code-mcp.onrender.com
Note: Hosted API runs in Map-Only mode. Use local MCP for full text.
Development
License
MIT License - See LICENSE