Paste a message from any HL7 v2 interface and see it broken into segments, fields, repetitions and components, each named and explained, with dates and coded values made readable.
An HL7 v2 message is a list of segments, one per line, each starting with a three-letter name. The first is always MSH, the message header, which says who sent the message, to whom, when, and what it is: MSH-9 holds the message type and trigger event, such as ADT^A01 for an admission or ORU^R01 for a lab result.
Each segment is split into numbered fields by |. A field such as PID-5 (patient name) can have components separated by ^ (family name, given name, middle name…), repeat with ~, and split further into subcomponents with &. Field numbers in MSH are offset by one because the field separator itself counts as MSH-1.
Common messages and segments
ADT (admit, discharge, transfer): PID for the patient, PV1 for the visit, NK1 for next of kin, AL1 for allergies.
ORM / OML (orders): ORC for the order and OBR for the test or procedure requested.
ORU (results): OBR for the order the results answer, then one OBX per result, with the value, units, reference range and abnormal flag.
ACK (acknowledgment): MSA-1 says whether the receiver accepted (AA), rejected (AR) or errored on (AE) the message.
Frequently asked questions
Is the HL7 message sent to a server?
No. Parsing happens in your browser, and nothing you paste is uploaded or stored. Only paste data you are allowed to handle, and prefer test messages over live patient data.
Which HL7 versions and messages does it support?
Any HL7 v2.x message (2.1 to 2.9). Field and component names follow v2.5.1 for the common segments: MSH, EVN, PID, PD1, NK1, PV1, PV2, ORC, OBR, OBX, NTE, AL1, DG1, PR1, MSA, ERR, MRG, SPM, IN1, GT1, TXA, SCH, RXA and SFT. Other segments, including site-specific Z-segments, are still split into fields and components, just without names.
My message is on one line, or has MLLP characters. Will it parse?
Segments can be separated by CR, LF or CRLF, and the MLLP start and end characters (VT, FS) are removed. If everything is on a single line, put each segment (MSH, PID, PV1…) on its own line first.
What are the ^ ~ \ & characters?
They are the encoding characters defined in MSH-2. | separates fields, ^ separates components, ~ separates repetitions of a field, \ starts an escape sequence and & separates subcomponents. A message may define its own, and the parser reads them from MSH.
Does it validate the message?
It checks the basics an interface engine rejects most often: the message starts with MSH, segment names are valid, and MSH-9 (message type), MSH-10 (control ID) and MSH-12 (version) are present. It does not validate against a full message profile.