A FHIR Validator is a conformance testing engine that parses a StructureDefinition and verifies that a given resource instance satisfies all defined invariants. It operates by loading the base FHIR specification, any applicable Implementation Guides like US Core, and custom FHIR Profiles, then executing a multi-phase check that includes schema validation against the JSON or XML definition, cardinality and data type verification, and terminology binding validation against specified ValueSets.
Glossary
FHIR Validator

What is FHIR Validator?
A FHIR validator is a software tool that programmatically checks FHIR resources and profiles against the specification's structural rules, cardinality constraints, data type requirements, and terminology bindings to ensure strict conformance.
The validation process generates an **OperationOutcome** resource detailing errors, warnings, and informational messages. Advanced validators support FHIRPath constraint evaluation, enabling complex cross-element rules beyond simple structural checks. This tool is a critical component of a FHIR Server's transaction processing and is essential for ensuring semantic interoperability before data exchange in production clinical workflows.
Core Validation Capabilities
A FHIR Validator is a conformance testing engine that verifies resources against the structural rules, terminology bindings, and business constraints defined by the base specification and implementation guides.
Structure Validation
Verifies that a resource's XML or JSON syntax is well-formed and that all mandatory elements are present. This includes checking cardinality (min/max occurrences), validating data types against the base FHIR schema, and ensuring that primitive values conform to their defined regular expressions. Structure validation catches missing required fields like Patient.name or Observation.status before more complex rules are evaluated.
Invariant Constraint Checking
Executes FHIRPath expressions embedded in profiles to enforce co-occurrence rules and conditional logic. Invariants are formal statements that must evaluate to true for a resource to be valid. Examples include:
obs-3: IfObservation.valueis absent,dataAbsentReasonmust be presentpat-1:Patient.nameorPatient.deceasedmust be present- Custom profile invariants like 'if
MedicationRequest.statusis active, thenintentmust be order'
Terminology Binding Validation
Validates that coded elements use concepts from the correct ValueSet with the required binding strength. The validator checks:
- required: The code must come from the specified ValueSet or the resource is invalid
- extensible: The code must come from the ValueSet if a suitable concept exists, otherwise a local code is allowed
- example/preferred: The code should come from the ValueSet but no enforcement occurs
This ensures
Observation.codeuses LOINC andMedicationRequest.medicationuses RxNorm where mandated.
Slicing Validation
Enforces discriminator-based rules that constrain repeated elements into distinct, named sub-groups called slices. Slicing is critical for profiles like US Core Blood Pressure, where the Observation.component array must contain exactly one systolic and one diastolic slice, each identified by a specific LOINC code. The validator checks that each slice meets its own cardinality, value constraints, and terminology bindings independently.
Profile Conformance
Asserts that a resource claiming conformance to a StructureDefinition (profile) satisfies all differential constraints layered on top of the base resource. This includes:
- Verifying that all Must Support elements are populated
- Checking that elements marked as fixed value or pattern match exactly
- Ensuring that extension URLs are recognized and their nested constraints are validated recursively
- Confirming that the
meta.profiletag matches the profile being validated against
Implementation Guide Compliance
Validates a resource against the complete set of rules packaged in a FHIR Implementation Guide (IG). An IG bundles multiple profiles, extensions, ValueSets, and global invariants. The validator resolves all dependencies, loads the package manifest, and tests the resource against every applicable profile simultaneously. This is the definitive check for US Core, Da Vinci, or CARIN conformance, producing an aggregated OperationOutcome with issues, locations, and severity levels.
Frequently Asked Questions
Clear, technical answers to the most common questions about FHIR validation, covering the mechanics, error interpretation, and architectural integration of conformance checking.
A FHIR Validator is a software engine that programmatically checks a FHIR resource instance against the formal constraints defined in the base FHIR specification, a specific Implementation Guide, and a set of FHIR Profiles. It works by parsing the resource's structure, verifying cardinality rules, checking data type conformance, and executing FHIRPath invariants. The validator does not just check syntax; it performs semantic validation by resolving Terminology Bindings to ensure that coded elements belong to the required ValueSet. The output is an OperationOutcome resource that categorizes issues by severity—fatal, error, warning, or information—providing a precise, machine-readable report on conformance.
Enabling Efficiency, Speed & Accuracy
Intelligent Analysis, Decision & Execution
We build AI systems for teams that need search across company data, workflow automation across tools, or AI features inside products and internal software.
Talk to Us
Search across company data
Give teams answers from docs, tickets, runbooks, and product data with sources and permissions.
Useful when people spend too long searching or get different answers from different systems.

Automate internal workflows
Use AI to route work, draft outputs, trigger actions, and keep approvals and logs in place.
Useful when repetitive work moves across multiple tools and teams.

Add AI to products and internal tools
Build assistants, guided actions, or decision support into the software your team or customers already use.
Useful when AI needs to be part of the product, not a separate tool.
Related Terms
Core specifications and resources that interact with the FHIR Validator to define and enforce data quality rules.
FHIR Profile
A constrained and extended subset of a base FHIR resource tailored to meet the specific data requirements of a particular country, domain, or implementation guide. The FHIR Validator uses profiles as the primary rulebook to check conformance.
- Defines cardinality (required/forbidden elements)
- Narrows terminology bindings to specific ValueSets
- Applies invariants (co-occurrence rules) expressed in FHIRPath
Terminology Binding
The mechanism in FHIR that links a coded element to a specific ValueSet, defining the allowed set of codes and the strength of that requirement. The validator checks if the supplied code is a member of the bound ValueSet.
- required: Must be from the defined ValueSet
- extensible: Must be from the ValueSet if a code exists, otherwise local codes allowed
- example: A hint for implementers, not enforced
FHIRPath
A path-based navigation and extraction language used in FHIR to query and compute expressions on FHIR data. The validator executes FHIRPath invariants to enforce complex co-occurrence constraints that cannot be expressed in a simple StructureDefinition.
- Example:
condition.exists() or severity.empty() - Used for slicing discriminators
- Powers search parameter extraction logic
FHIR OperationOutcome
A FHIR resource returned by a server to provide detailed information about the success or failure of an operation. The FHIR Validator returns an OperationOutcome containing a list of issues with severity levels.
- error: A violation of a required constraint
- warning: A best practice violation
- information: A structural hint
- Each issue includes a
locationstring pinpointing the exact path of the error
FHIR Implementation Guide
A published set of rules, profiles, and documentation that defines how FHIR must be used to solve a specific clinical or administrative interoperability problem. The validator is the gatekeeper that certifies a server or document conforms to an IG's full set of constraints.
- Bundles all profiles, extensions, and ValueSets
- Defines capability statements for server conformance
- Examples: US Core, Da Vinci PDex, IPA
FHIR Shorthand (FSH)
A concise, text-based authoring language used to define FHIR profiles, extensions, and implementation guides, which is then compiled into formal FHIR definitions. The SUSHI compiler transforms FSH into the StructureDefinitions that the FHIR Validator consumes.
Profile: MyPatientdefines a new constrained profile* status 1..1sets cardinality* identifier from http://example.org/vsbinds a ValueSet

About the author
Prasad Kumkar
CEO & MD, Inference Systems
Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.
His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.
Partnered with leading AI, data, and software stack.
How We Work
Custom AI workflows for your Business
One-fit-all AI don't work for modern businesses. At Inferensys, we aim to understand your business & custom requirements; which we use to define most efficient agentic workflows, the data, and the tools for your business.
01
Review the use case
We understand the task, the users, and where AI can actually help.
Read more02
Pick the right approach
We define what needs search, automation, or product integration.
Read more03
Build the first useful version
We implement the part that proves the value first.
Read more04
Improve from there
We add the checks and visibility needed to keep it useful.
Read moreThe first call is a practical review of your use case and the right next step.
Talk to Us