X12 vs EDIFACT: What's the Difference?
There is no single global EDI standard. Two dominate the world, and which one you encounter depends mostly on geography. ANSI X12 rules North America; UN/EDIFACT rules most of the rest of the world. They do the same job — moving orders, invoices, and shipping notices between companies — but they look different on the wire.
The quick comparison
- Region: X12 is North America; EDIFACT is international (Europe, Asia, and global trade).
- Naming: X12 uses numbers (850, 810, 856). EDIFACT uses names (ORDERS, INVOIC, DESADV).
- Governing body: X12 is maintained by ASC X12; EDIFACT by the United Nations (UN/CEFACT).
Syntax differences
The biggest visible difference is the delimiters — the characters that separate the pieces.
X12
ST*850*0001~ BEG*00*SA*PO-99831**20240115~
Segments end with a tilde ~, elements are separated by an asterisk *, and the envelope is defined by the ISA header.
EDIFACT
UNH+1+ORDERS:D:96A:UN' BGM+220+PO-55012+9'
Segments end with an apostrophe ', elements with a plus +, components with a colon :, and an optional UNA string can declare those delimiters explicitly.
Structure differences
Both wrap their content in envelopes, but the envelope segments are named differently:
- X12:
ISA/GS/ST…SE/GE/IEA - EDIFACT:
UNB/UNG/UNH…UNT/UNE/UNZ
In both, the innermost header (ST for X12, UNH for EDIFACT) is what tells you which document type you are looking at.
Which transaction maps to which
The same business document exists in both standards under different labels:
- Purchase order: 850 (X12) = ORDERS (EDIFACT)
- Invoice: 810 = INVOIC
- Advance ship notice: 856 = DESADV
- Order response: 855 = ORDRSP
- Payment/remittance: 820 = REMADV
- Functional acknowledgment: 997 = CONTRL
Which one will you deal with?
If you trade primarily with U.S. partners, you will see X12. If you trade with European or global partners, expect EDIFACT. Many companies that operate internationally have to handle both.
EdiPeek reads both standards. Paste an X12 or an EDIFACT message and get a plain-English breakdown — in your browser, nothing uploaded.
X12 viewer EDIFACT viewer