Guide

A Practical Guide to the Four Types of Primary Law: Statutes, Regulations, Constitutions, & Case Law

By John Phamvan. Published June 15, 2026.

A field guide for attorneys building technology, compliance professionals, business owners, and curious laypeople who want to understand what “the law” actually is, and where to find each piece of it.

Key takeaways

  • Primary law is the law itself, and it comes in four main forms: statutes and codes, regulations and administrative codes, constitutions, and case law, with agency guidance as a large additional layer.
  • For regulatory compliance, OpenLaws is the main source: structured, continuously updated statutes and regulations across all 50 states and the U.S. Code and CFR. Those are all available through a single API.
  • For case law and court dockets, CourtListener, from the nonprofit Free Law Project, is the leading open resource.
  • Statutes and regulations change in place and must be kept current, since an out-of-date copy can be flat wrong, stating a rule that has since been amended or repealed.
  • AI models and quick web searches often return stale or fabricated law, so trustworthy answers need to be grounded in up-to-date, authoritative legal data.

Why the source of your law matters

When most people picture “the law,” they picture a courtroom. But court decisions are only one part of the picture. Under every case sits a much larger body of written law: statutes passed by legislatures, regulations written by agencies, constitutions that set the basic rules, and a broad layer of agency guidance that never gets folded into a tidy code.

Law that comes straight from a government body is called primary law (or, in lawyer-speak, primary authority), as opposed to secondary sources like treatises or practice guides that explain it. Not every type binds with the same force, as we will see, but all of it comes from the government rather than a commentator, and it is the text that actually governs.

Primary law does not live in one place, and the right source depends on what you are doing. For broad primary-law research, OpenLaws and CourtListener work well together: OpenLaws covers codified law (statutes, regulations, and constitutions across 53 U.S. jurisdictions), and CourtListener, built by the nonprofit Free Law Project, offers one of the largest open collections of case law and federal dockets online. For regulatory compliance, the picture is simpler: OpenLaws is the main source, because compliance teams rely on statutes, regulations, and agency guidance.

If you are new to OpenLaws, it is a legal data company that delivers structured, continuously updated U.S. statutes, regulations, and constitutions across 53 jurisdictions, sourced from over 170 authoritative sources, through a developer-friendly API. Below, we walk through the main types of primary law, who needs each one, which dataset to use, and where the field is still being built out.

Type of primary law What it is Who needs it most Where to find it
Statutes & codes Laws passed by legislatures, organized by subject into codes Attorneys, compliance teams, business owners, public policy and gov’t affairs OpenLaws
Rules, regulations, & administrative codes Agency rules that carry the force of law, such as the CFR Compliance professionals, regulated businesses OpenLaws
Constitutions The foundational federal and state law that limits government Civil rights, appellate, and policy work OpenLaws
Case law & dockets Court opinions and the litigation records behind them Litigators, researchers, enforcement-watchers CourtListener

1. Statutes and codes

What it is. Statutes are laws passed by a legislature: Congress at the federal level, and state legislatures in each state. Organized by subject into titles and sections, they become a code. The U.S. Code is the federal example; every state has its own, such as the California Codes or the Texas statutes. A “session law” is the law as originally enacted; the codified version is that same law placed into its permanent home in the code and updated as later amendments change it.

Why it matters. Statutes are the backbone of many legal questions. Can my landlord do that? What counts as wire fraud? The answer often starts with a statute, and codes are how you find the law currently in force rather than a one-off bill from a particular year.

Who reaches for it. Attorneys in statute-heavy practice areas work in them daily, from tax and employment to criminal and environmental law, though transactional or appellate work may lean elsewhere. Compliance professionals map obligations to specific code sections; business owners hit them from employment to licensing to tax; and laypeople meet them in areas like tenant rights or small-claims limits.

Coverage: Core OpenLaws territory. OpenLaws covers statutes and codes at the federal level and in all 50 states, D.C., and Puerto Rico, normalized into a single structured data model so you and AI agents can search by keyword, citation, or plain-language name across jurisdictions at once.

2. Rules, regulations, and administrative codes

What it is. Legislatures rarely have the time or expertise to spell out every detail, so they delegate. Agencies fill the gaps by issuing regulations (also called rules), organized into an administrative code. At the federal level, this is the Code of Federal Regulations (the CFR); states have their own. Regulations carry the force of law: a rule from an agency you have never heard of can bind you as firmly as a statute passed by Congress.

Why it matters. For most regulated activities, the regulations hold the real operating details. A statute might say “food must be safe,” but the regulation gives the actual temperature, labeling, and recordkeeping requirements. In finance, healthcare, pharma, energy, food, transportation, or any regulated industry, the regulations often matter more day-to-day than the statutes behind them.

Regulations are also harder to stay on top of than statutes. A statute is relatively contained and easy to collect, but regulations are voluminous, spread across many agencies, and revised far more often, so they fall out of date much faster. Keeping them current is real work, and it is exactly what determines whether a compliance source can be trusted.

Who reaches for it. Compliance professionals build their jobs around regulations; attorneys advising regulated clients need them constantly; business owners in licensed fields ignore them at their peril; and regular folks encounter them around government benefits eligibility, immigration, and consumer protection.

Coverage: Also core OpenLaws territory, sitting right alongside the statutes in the same searchable model, so you can move between a statute and its implementing regulations without changing tools.

3. Constitutions

What it is. A constitution is the foundational law that sets up a government and limits what it can do. The U.S. Constitution is the famous one, but every state has its own, often longer and more detailed. Constitutions sit atop the hierarchy: a statute or regulation that conflicts with the relevant constitution can be struck down.

Why it matters. State constitutions cover more than people expect, from education funding and taxation limits to individual rights that sometimes go further than their federal counterparts.

Who reaches for it. Attorneys in civil rights, government, or appellate matters; policy professionals tracking the limits of government authority; business owners facing state-level tax or regulatory challenges; and laypeople researching their rights.

Coverage: OpenLaws covers constitutions for federal and state jurisdictions in the same unified dataset, so the foundational law sits in context next to the statutes and regulations built on top of it.

4. Case law and dockets

What it is. Case law is the body of written court decisions, or opinions, in which judges explain reasoning that becomes binding or persuasive authority for later cases. Published opinions are designated as precedent, binding lower courts within the same jurisdiction under stare decisis (a higher court in another jurisdiction only persuades). Unpublished opinions resolve a dispute but carry limited or no precedential weight; in federal court, they can still be cited, even when labeled non-precedential, under Federal Rule of Appellate Procedure 32.1 for decisions issued on or after January 1, 2007.

Next to case law sit dockets: the official running record of everything filed in a case, from the complaint through motions, orders, and the documents themselves. At the federal level, this lives in PACER, the government’s paywalled system. Dockets are how you track active litigation and pull the actual filings, not just the final opinion.

Why it matters. Case law shows how the written law has actually been applied; a statute can look clear until you read the opinions interpreting it. Dockets matter when you need to follow live litigation or retrieve a specific filing.

Who reaches for it. Litigators and appellate attorneys, plus compliance teams watching enforcement trends, business owners monitoring industry lawsuits, journalists, researchers, and laypeople trying to understand how a law played out.

Coverage: For case law and federal dockets, CourtListener is the open resource I point people to first. CourtListener hosts over 9M decisions from more than 2,000 courts, both published and unpublished. Its RECAP Archive is the biggest open collection of federal court data online, with hundreds of millions of docket entries and millions of documents pulled out from behind the PACER paywall.

Why staying current matters

Codified law and case law age in completely different ways, and that difference is the heart of what OpenLaws does.

Statutes and regulations are living documents. When a legislature amends a statute or an agency revises a rule, the official text itself changes, and the old language is replaced. An out-of-date copy is not just incomplete; it can be flat wrong, describing a requirement that no longer exists or missing one that now applies. We have seen emergency COVID-19 regulations simply disappear from state agency websites rather than be marked as repealed! For compliance, where the whole job is doing what the current rule requires, the in-force version is the entire point.

Case law works the other way. An opinion’s text is essentially fixed once issued, not continuously revised the way a legislature edits a statute. Newer decisions add to the body of law rather than rewriting the old ones, so the library mostly grows rather than shifts underneath you. Recency still matters: a later ruling can change how an opinion is read or overturn it outright, so the thing to verify is whether a case is still good law, not whether its text was quietly edited last week.

Keeping statutes and regulations up to date is OpenLaws’ main benefit for companies and customers. Tracking text that is constantly amended across 53 jurisdictions is difficult, unglamorous work, and getting it right is what separates a reliable compliance source from a stale one. A stale regulation is worse than missing data: it appears authoritative even though it is wrong.

Why a quick search or an AI answer isn’t enough

The temptation today is to ask an AI model or run a quick web search and trust the answer. For primary law, that is risky, and the risk is worst exactly where the stakes are highest: fast-changing statutes and regulations, and case law that may no longer be good law.

A model knows only what it absorbed during training, frozen at some cutoff. Ask it about a statute or regulation, and it will often answer confidently in language since amended or repealed, with no hint that anything has changed. Models can also fabricate authority outright.

A quick web search has different but equally real problems. You might land on an unofficial copy, an outdated version, the wrong jurisdiction, or a blog post describing how the law used to read. Search engines rank for relevance and popularity, not for whether a statute is in force or a case has been overturned. A decision can be reversed, superseded by statute, or undercut by a later ruling, and the page quoting it looks exactly as authoritative as the day it was published.

None of this makes AI the enemy. The problem is ungrounded AI and unverified search. The fix is to feed AI models reliable, up-to-date primary law, so the answer is anchored to the text that governs today. That grounding layer is exactly what OpenLaws provides, whether you research by hand or build an AI product on our API.

The frontier: where OpenLaws is investing

The four types above are the law as it stands today. We are also pushing into five areas that most legal databases handle badly, because that messy, scattered material is exactly the kind of thing we are good at turning into standardized, structured, searchable data. Additionally, codified law has a lifecycle and is often monitored by companies and attorneys before it becomes primary law; OpenLaws is working to add those datasets to enable monitoring of proposed laws.

Legislation and bills. Enacted statutes are settled law, but the bills moving through Congress and the state legislatures are not. Tracking pending legislation lets you see which rules might change, and how, before they take effect. We are working to bring bills into the same structured model as the statutes they would amend.

Proposed rules and regulations. Before a regulation becomes final, an agency publishes it as a proposed rule and opens a public comment period. Following proposed rules lets compliance teams prepare early and weigh in while the text can still change. We are working to cover this rulemaking pipeline alongside the final regulations already in OpenLaws.

Uncodified administrative law. Agencies do more than issue formal regulations. They also publish a large body of sub-regulatory material that explains how they interpret and enforce the law: guidance documents and manuals (such as FDA guidance on FDA.gov and the CMS Internet-Only Manuals on CMS.gov), interpretive rules and policy statements, advisory opinions and no-action letters (like the SEC’s), and the IRS’s revenue rulings, revenue procedures, notices, and many other PDFs. A related layer is agency adjudication: the case-by-case decisions agencies issue when they act like courts, from immigration and labor boards to securities proceedings. Most of this is not binding the way a statute or regulation is, but it is where regulated companies spend much of their time, and it is scattered across agency websites with no central index. If it sounds like a lot, it is! We are working to add it to our dataset, starting with agencies such as the CFPB, FDA, and CMS.

Court rules. Courts set their own procedural law: the Federal Rules of Civil Procedure, Criminal Procedure, Evidence, and Appellate Procedure, plus the local rules each court adopts. They govern how a case actually proceeds, and overlooking a local rule can sink a filing. We are working to bring court rules, including local rules, into the same structured data model.

Executive orders. Presidential executive orders are already in OpenLaws and updated frequently. The bigger gap is at the state level, where governors issue executive orders that carry real legal weight but are scattered and inconsistently published. We are working to bring state executive orders into the same structured model.

Start Here

If regulatory compliance is your main job, start with OpenLaws. Compliance is overwhelmingly a question of codified law and agency guidance: what statutes, regulations, and constitutions require, and how agencies interpret them. That is the home turf OpenLaws was built for, across 53 U.S. jurisdictions in one structured, searchable dataset. Explore the coverage and integrate it through a single API.

If broad primary-law research is your goal, use both. For case law and dockets, add CourtListener, from the nonprofit Free Law Project, an open resource for opinions and federal court records. Pair it with OpenLaws’s codified law, and the two fit together like peanut butter and jelly: codified law tells you what the rules are, and case law tells you how they have been applied. Use both, and there is little of American law you cannot reach.

About the author

John Phamvan is the founder of OpenLaws PBC, a public benefit legal data company that makes U.S. statutes, regulations, and constitutions available as structured, continuously updated data through a single API. He also leads Kind Systems, a CivicTech software consultancy. He writes about legal data infrastructure, regulatory compliance, and building reliable AI on top of primary law.

Frequently asked questions