Introduction to FIX
FIX (Financial Information eXchange) is the industry-standard protocol for exchanging structured trading messages between banks, brokers, venues, and internal systems. It is text-based, tag-oriented, and designed for low-latency electronic trading — especially FX ESP (executable streaming prices).
Why FIX exists
Before FIX, every counterparty pair often had a bespoke wire format. FIX standardises:
- Semantics — what a quote, order, or execution means
- Field numbering — tags like
55(Symbol) or44(Price) - Session behaviour — how two endpoints stay connected and recover from gaps
That shared vocabulary is what makes multi-party integration and honest benchmarking possible.
Message shape
A FIX message is a stream of tag=value fields separated by ASCII SOH (0x01). Human-readable views usually show | instead of SOH:
8=FIX.4.4|9=…|35=D|49=SENDER|56=TARGET|34=12|52=20260629-10:00:00.000|11=OID1|55=EUR/USD|54=1|38=1000000|40=2|44=1.0850|10=…|
Key header tags:
| Tag | Name | Role |
|---|---|---|
| 8 | BeginString | FIX version (FIX.4.4) |
| 35 | MsgType | Message type (D = NewOrderSingle, S = Quote, …) |
| 49 | SenderCompID | Who sent the message |
| 56 | TargetCompID | Who should receive it |
| 34 | MsgSeqNum | Per-direction sequence number |
| 52 | SendingTime | Timestamp |
The checksum (tag 10) closes every message.
Two layers
FIX is usually discussed in two layers:
- Session layer — connectivity and reliability: Logon (
A), Logout (5), Heartbeat (0), Resend Request (2), Sequence Reset (4). Sequence numbers must stay in sync; gaps trigger recovery. - Application layer — business messages: Market Data (
W,X), Quote (S), NewOrderSingle (D), ExecutionReport (8), and so on.
4H implements both layers in Java, driven from FIX specification artefacts rather than hand-coded one-offs.
Transport
Production FIX sessions typically run over TCP (often with a VPN or leased line). TLS may wrap the socket depending on counterparty policy. The evaluation package uses plain TCP on localhost so you can focus on message flow first.
FIX versions
You will still see FIX 4.2 in legacy equities stacks. FX ESP and most modern sell-side profiles target FIX 4.4. ExampleBank and Lucid in the 4H evaluation package speak FIX 4.4.
A minimal session lifecycle
- TCP connect (initiator → acceptor)
- Logon — parties agree comp IDs, heartbeat interval, and optional credentials
- Heartbeats — prove the link is alive when idle
- Application traffic — quotes, orders, executions
- Logout — graceful teardown (or disconnect on error)
When you run the ExampleBank demo, watch the server and client logs: you are seeing this lifecycle in real time.
Where to go next
- Getting started with 4H — evaluation package layout and first run
- ExampleBank TCP demo — quote and trade round-trip with repeating groups
- 4H Academy — FIX fundamentals — short lessons and quizzes