Complete United States Code in structured JSON format. Mirror of uscode.house.gov with automated weekly updates.
This repository maintains a complete, up-to-date mirror of the United States Code in machine-readable JSON format. All data is sourced from the official Office of the Law Revision Counsel (OLRC) at the US House of Representatives.
- Primary: uscode.house.gov/download
- Format: XML (USLM schema) converted to JSON
- Update Frequency: Weekly (Sundays at 00:00 UTC)
- License: Public Domain (17 U.S.C. § 105)
us-code/
├── README.md
├── data/
│ ├── titles/
│ │ ├── title-01-general-provisions.json
│ │ ├── title-02-the-congress.json
│ │ └── ... (all 53 titles)
│ └── metadata.json
├── schema/
│ └── us-code-section.schema.json
├── scripts/
│ ├── download.sh # Download from uscode.house.gov
│ ├── parse-xml.js # Parse XML to JSON
│ └── validate.js # Validate against schema
└── .github/workflows/
└── update.yml # Scheduled/manual update PRs
Each title is stored as a JSON file containing all sections:
{
"title": "1",
"titleName": "General Provisions",
"chapter": "1",
"chapterName": "Rules of Construction",
"section": "1",
"sectionName": "Words denoting number, gender, and so forth",
"text": "...",
"notes": [],
"amendments": [],
"effectiveDate": "...",
"sourceUrl": "https://uscode.house.gov/view.xhtml?req=...",
"lastUpdated": "2026-06-06"
}- Last Updated: See latest commit date
- Current Release Point: Public Law 119-95 (05/29/2026)
- Total Titles: 53 (plus appendices)
- Total Sections: ~60,000+
# Clone the repository
git clone https://github.com/CourtGPT/us-code.git
# Or download specific title
curl -O https://raw.githubusercontent.com/CourtGPT/us-code/main/data/titles/title-01-general-provisions.jsonconst usCode = require('./data/titles/title-01-general-provisions.json');
// Find specific section
const section1 = usCode.sections.find(s => s.section === '1');
console.log(section1.text);GitHub Actions checks the official OLRC release-point page every Sunday at 00:00 UTC and can also be started manually. The updater discovers the current public-law release and XML archive instead of hard-coding a release number, stages the archive, generates deterministic JSON, validates the output, and opens a pull request only when the generated data changes. A no-change run creates no commit.
The pull request includes data/metadata.json, which records the source release point, source URL, parser, title count, and section count. The workflow requires the parser fixture tests and data validation to pass before it opens or updates the pull request.
We welcome contributions! Please see CONTRIBUTING.md for guidelines.
All data in this repository is sourced from official US government publications and is in the public domain pursuant to 17 U.S.C. § 105. This repository is an independent mirror and is not affiliated with or endorsed by the US House of Representatives or the Office of the Law Revision Counsel.
- congress-tracker - Track congressional bills and votes
- house-documents - House XML documents archive
- caselaw-access - Public domain case law
CourtGPT is building open-source legal data tools and AI-powered legal research. Follow us on X @courtgpt.
Disclaimer: This repository is for informational purposes only. It does not constitute legal advice. Always consult official sources and qualified legal professionals for legal matters.