Written and maintained by CASRAI Editorial Board
Last updated
The HL7 FHIR Encounter resource represents an interaction between a patient and one or more healthcare providers for the purpose of providing healthcare services or assessing the health status of a patient. Within the HL7 Fast Healthcare Interoperability Resources (FHIR) workflow architecture, Encounter serves as the temporal, organizational, and clinical context anchor that binds together clinical observations, diagnostic reports, medication administrations, procedures, and billing claims generated during an outpatient visit, emergency department admission, inpatient stay, or virtual telehealth session.
What Does the FHIR Encounter Resource Represent? Scope and Resource Boundaries
In clinical data repositories and EHR FHIR APIs, architects frequently need to distinguish Encounter from three closely related workflow and administrative resources: Appointment, EpisodeOfCare, and Account / Claim.
| FHIR Resource | Primary Temporal & Clinical Scope | Typical Trigger Event | Relationship to Encounter |
|---|---|---|---|
Appointment |
A booking of a healthcare event among patient(s), practitioner(s), and device(s) for a specific future date/time slot. | Scheduling request (HL7 v2 SIU^S12) or patient portal self-scheduling. |
Referenced via Encounter.appointment once the patient arrives or checks in and clinical workflow begins. |
Encounter |
The actual clinical interaction—from patient arrival/registration through triage, bed movement, clinical care, and discharge. | Patient check-in, registration, or admission (HL7 v2 ADT^A01 / ADT^A04). |
Provides the context / encounter reference for Observation, Condition, Procedure, and DiagnosticReport. |
EpisodeOfCare |
A longitudinal care program or case management container managing a specific condition across multiple visits (e.g., prenatal care, oncology protocol, cardiac rehabilitation). | Enrollment in a disease management or specialty care program. | One EpisodeOfCare spans many distinct Encounter instances via Encounter.episodeOfCare. |
Account / Claim |
Financial aggregation of charges, coverage, and adjudication tied to one or more clinical interactions. | Charge capture (HL7 v2 DFT^P03) and X12 837 claim generation. |
Linked via Encounter.account or Claim.item.encounter; a single inpatient account may span pre-admission and admission encounters. |
Furthermore, the HL7 FHIR specification allows hierarchical encounter nesting via the Encounter.partOf element. For example, when a patient is admitted through the emergency department and subsequently transferred to an intensive care unit and a step-down medical ward under a single hospital stay, an organization can either track room movements in a single Encounter.location[] array or link departmental sub-encounters to an overarching administrative admission Encounter via Encounter.partOf.
What Are the Status Lifecycle States of a FHIR Encounter?
Every FHIR R4 Encounter resource requires two mandatory core elements (`1..1` cardinality): Encounter.status (bound with Required strength to the EncounterStatus value set) and Encounter.class (bound with Extensible strength to the HL7 v3 ActEncounterCode value set).
1. Encounter.status State Machine (FHIR R4)
planned: The Encounter has been created prior to the patient’s actual arrival (for example, pre-admission registration or conversion of a scheduledAppointmentinto a pre-admit record).arrived: The Patient is present for the encounter, such as having checked in at the front desk or emergency department registration kiosk, though clinical evaluation or triage has not yet commenced.triaged: The patient has been assessed for clinical priority and acuity (e.g., Emergency Severity Index [ESI] scoring in an emergency department) and is awaiting definitive provider evaluation or bed assignment.in-progress: The clinical encounter has begun and the patient is actively receiving care—either in an ambulatory exam room, an inpatient bed, or a connected telehealth session.onleave: The encounter has begun, but the patient is temporarily absent from the facility with clinical permission (for example, a weekend therapeutic pass from an inpatient rehabilitation or behavioral health unit) before returning to complete the stay.finished: The clinical interaction and administrative visit have concluded (patient discharged from the hospital or checked out of the outpatient clinic). Note: In FHIR R5, the codefinishedwas renamed tocompletedandonleavewas split intoon-holdanddiscontinued, while R4 remains the baseline for US Core and ONC certification.cancelled: The Encounter ended before it actually started (e.g., a pre-admission or arrived visit was aborted prior to clinical evaluation).entered-in-error: The resource instance should never have been created (such as registering the wrong patient record) and must be ignored by clinical decision support and analytics pipelines.unknown: The encounter status cannot be determined from the source system (commonly used when ingesting incomplete historical legacy records).
Because an encounter transitions through multiple states and care settings over time, FHIR provides two audit arrays inside the resource: Encounter.statusHistory[] (recording each historical status and its period start/end timestamps) and Encounter.classHistory[] (recording transitions in patient class, such as an emergency visit [EMER] converting into an observation stay [OBSENC] and then a full inpatient admission [IMP]).
2. Encounter.class Codes (v3-ActEncounterCode)
AMB(ambulatory): Outpatient clinic, office visit, or ambulatory diagnostic encounter where the patient is not admitted overnight.IMP(inpatient encounter): Acute hospital admission where the patient is admitted to an inpatient bed for lodging and continuous nursing care.ACUTE/NONAC: Specialized inpatient subtypes distinguishing acute inpatient hospital care from non-acute long-term or sub-acute inpatient care.EMER(emergency): Unscheduled visit to an Emergency Department (ED) for evaluation and stabilization of an acute condition.OBSENC(observation encounter): Hospital observation stay (typically 24–48 hours) used to determine whether a patient requires formal inpatient admission or can be safely discharged.VR(virtual): Synchronous or asynchronous telemedicine encounter conducted via video, audio, or secure digital messaging where the patient and practitioner are in separate physical locations.HH(home health): Healthcare encounter delivered at the patient’s residence by visiting nurses, therapists, or clinicians.
How Does FHIR Encounter Map to HL7 v2 PV1 Segments and ADT Events?
Healthcare integration engines and HL7 v2 parsers continuously translate Admission, Discharge, and Transfer (ADT) feeds into FHIR Encounter resources packaged inside a FHIR Bundle. In HL7 v2.x, visit-level context is carried primarily in the PV1 (Patient Visit) and PV2 (Patient Visit — Additional Information) segments, while state transitions are driven by the MSH-9 / EVN-1 trigger event code.
1. HL7 v2 ADT Trigger Event to Encounter.status Mapping
| HL7 v2 Message Type | ADT Trigger Event Description | Target FHIR Encounter.status & Action |
|---|---|---|
ADT^A05 |
Pre-admit a patient | Sets Encounter.status = "planned". |
ADT^A04 |
Register a patient (outpatient / ED arrival) | Sets Encounter.status = "arrived" or "in-progress" depending on local check-in workflow; populates Encounter.period.start. |
ADT^A01 |
Admit / visit notification (inpatient) | Sets Encounter.status = "in-progress" and Encounter.class.code = "IMP"; populates Encounter.period.start. |
ADT^A02 |
Transfer a patient | Keeps Encounter.status = "in-progress"; closes prior Encounter.location[] entry (completed) and appends new active location from PV1-3. |
ADT^A06 / ADT^A07 |
Change an outpatient to an inpatient / vice versa | Appends prior class to Encounter.classHistory[] and updates Encounter.class (e.g., EMER or OBSENC to IMP). |
ADT^A21 / ADT^A22 |
Patient goes on / returns from a leave of absence | A21 sets Encounter.status = "onleave"; A22 restores Encounter.status = "in-progress". |
ADT^A03 |
Discharge / end visit | Sets Encounter.status = "finished", populates Encounter.period.end (PV1-45) and Encounter.hospitalization.dischargeDisposition (PV1-36). |
ADT^A11 |
Cancel admit / visit notification | Sets Encounter.status = "cancelled" (or "entered-in-error" if voiding a mistaken registration). |
2. Field-by-Field HL7 v2 PV1 Segment to FHIR Encounter Mapping
| HL7 v2 Field | HL7 v2 Field Name | FHIR R4 Encounter Element |
Mapping & Transformation Notes |
|---|---|---|---|
PV1-19 |
Visit Number (CX) |
Encounter.identifier |
Primary business identifier for the visit (`type = VN` from `v2-0203`), preserving assigning authority and namespace. |
PV1-2 |
Patient Class (IS, Table 0004) |
Encounter.class |
Maps v2 Table 0004 codes (`I` → `IMP`, `O` → `AMB`, `E` → `EMER`, `P` [Preadmit] → `status=planned`, `B` [Obstetrics] → `IMP`). |
PV1-3 & PV1-6 |
Assigned Patient Location / Prior Patient Location (PL) |
Encounter.location[] |
Point of Care (`PL.1`), Room (`PL.2`), Bed (`PL.3`), and Facility (`PL.4`) resolve to Location references with status = active (for `PV1-3`) and status = completed (for `PV1-6`). |
PV1-4 |
Admission Type (IS, Table 0007) |
Encounter.type / Encounter.priority |
Classifies elective, urgent, emergency, or newborn admission context. |
PV1-7, PV1-8, PV1-9, PV1-17 |
Attending, Referring, Consulting, Admitting Doctor (XCN) |
Encounter.participant[] |
Each XCN maps to a Practitioner reference paired with a participant.type code from v3-ParticipationType (`ATND`, `REF`, `CON`, `ADM`). |
PV1-10 |
Hospital Service (IS, Table 0069) |
Encounter.serviceType |
Clinical service line (e.g., Cardiology, Orthopedics, Medical Intensive Care). |
PV1-14 |
Admit Source (IS, Table 0023) |
Encounter.hospitalization.admitSource |
Indicates origin prior to admission (e.g., physician referral, transfer from another acute hospital or skilled nursing facility). |
PV1-36 |
Discharge Disposition (IS, Table 0112) |
Encounter.hospitalization.dischargeDisposition |
Indicates post-discharge destination (e.g., home self-care, home health agency, skilled nursing facility, expired, left against medical advice). |
PV1-44 & PV1-45 |
Admit Date/Time & Discharge Date/Time (TS) |
Encounter.period.start & Encounter.period.end |
Converted from HL7 v2 timestamp (`YYYYMMDDHHMMSS`) to ISO 8601 `dateTime` with explicit timezone offset. |
US Core Encounter Profile & Annotated JSON Example
To comply with the ONC Health Data, Technology, and Interoperability (HTI-1) certification criterion 170.315(g)(10), certified EHR systems expose the HL7 US Core Encounter Profile. US Core constrains base FHIR R4 Encounter by requiring Must Support on identifier, status, class, type (bound extensible to CPT, SNOMED CT, or HCPCS encounter codes), subject (referencing a US Core Patient), participant (type, period, and individual), period, reasonCode or reasonReference, hospitalization.dischargeDisposition, and location.
{
"resourceType": "Encounter",
"id": "enc-inpatient-94821",
"meta": {
"profile": [
"http://hl7.org/fhir/us/core/StructureDefinition/us-core-encounter"
]
},
"identifier": [
{
"use": "official",
"type": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v2-0203",
"code": "VN",
"display": "Visit number"
}
]
},
"system": "urn:oid:2.16.840.1.113883.3.1984.1.2",
"value": "V-2026-0094821"
}
],
"status": "finished",
"class": {
"system": "http://terminology.hl7.org/CodeSystem/v3-ActCode",
"code": "IMP",
"display": "inpatient encounter"
},
"type": [
{
"coding": [
{
"system": "http://www.ama-assn.org/go/cpt",
"code": "99223",
"display": "Initial hospital inpatient or observation care, per day, high level of medical decision making"
}
]
}
],
"subject": {
"reference": "Patient/pat-10492",
"display": "Elena Rostova"
},
"participant": [
{
"type": [
{
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/v3-ParticipationType",
"code": "ATND",
"display": "attender"
}
]
}
],
"period": {
"start": "2026-03-14T09:15:00-05:00",
"end": "2026-03-17T14:30:00-05:00"
},
"individual": {
"reference": "Practitioner/prac-3310",
"display": "Dr. Marcus Vance, MD"
}
}
],
"period": {
"start": "2026-03-14T08:42:00-05:00",
"end": "2026-03-17T14:30:00-05:00"
},
"reasonCode": [
{
"coding": [
{
"system": "http://snomed.info/sct",
"code": "233604007",
"display": "Pneumonia"
}
]
}
],
"hospitalization": {
"admitSource": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/admit-source",
"code": "emd",
"display": "From accident/emergency department"
}
]
},
"dischargeDisposition": {
"coding": [
{
"system": "http://terminology.hl7.org/CodeSystem/discharge-disposition",
"code": "home",
"display": "Home"
}
]
}
},
"location": [
{
"location": {
"reference": "Location/loc-medsurg-4b-bed12",
"display": "Med-Surg Unit 4B, Room 412, Bed A"
},
"status": "completed",
"period": {
"start": "2026-03-14T09:10:00-05:00",
"end": "2026-03-17T14:30:00-05:00"
}
}
]
}
Frequently Asked Questions
What does the FHIR Encounter resource represent?
The FHIR Encounter resource represents the actual clinical or administrative interaction between a patient and healthcare provider(s) for the purpose of delivering healthcare services or assessing a patient’s health status. Unlike Appointment (which represents a scheduled future booking) or EpisodeOfCare (which tracks a longitudinal care program across multiple visits), Encounter tracks a single outpatient visit, emergency department presentation, virtual telemedicine consultation, or inpatient hospital stay from arrival to discharge.
How does FHIR Encounter map to HL7 v2 PV1 segments?
In HL7 v2-to-FHIR integration pipelines, the PV1 (Patient Visit) segment maps directly to Encounter elements: PV1-19 (Visit Number) maps to Encounter.identifier; PV1-2 (Patient Class) maps to Encounter.class (IMP, AMB, EMER); PV1-3 and PV1-6 map to Encounter.location[]; PV1-7, PV1-8, PV1-9, and PV1-17 map to Encounter.participant[] with ATND, REF, CON, and ADM participation codes; PV1-14 and PV1-36 map to Encounter.hospitalization.admitSource and dischargeDisposition; and PV1-44/PV1-45 map to Encounter.period.start and end, while the ADT trigger event (A01, A03, A04, A11) determines Encounter.status.
What are the status lifecycle states of a FHIR Encounter?
In FHIR R4, Encounter.status uses a required nine-state value set: planned (created prior to arrival), arrived (patient checked in and present), triaged (acuity assessed, awaiting care), in-progress (active care underway), onleave (patient temporarily absent on authorized pass), finished (visit or stay completed and discharged), cancelled (aborted before clinical start), entered-in-error (invalid record created by mistake), and unknown.







