Pull any live ADS-B feed and every aircraft arrives tagged with a 6-character hex string — 40621D, A835AF, 0A0022. It's not the tail number, it's not the flight number, and if you're building on tracking data you need to know exactly what it is. That code is the aircraft's Mode S hex code, better known as its ICAO 24-bit address, and it's the machine identifier that ties a raw radio signal back to a real airframe. This post explains what it is, how it's structured, and how to resolve one into full aircraft data by API.
What the hex code actually is
Every Mode S transponder — the avionics box that answers radar interrogations and broadcasts ADS-B — is programmed with a 24-bit address uniquely assigned to that airframe by its national registration authority. Twenty-four bits is a number from 0 to 16,777,215, and it's almost always written as 6 hexadecimal digits (0x000000–0xFFFFFF) because hex maps cleanly onto the underlying bits. So 40621D isn't a serial or a code someone chose to look nice — it's literally the 24-bit number burned into the transponder, printed in base 16.
That address is broadcast in every Mode S and ADS-B transmission, which is how a ground receiver knows which aircraft each position report belongs to. It's the join key of the entire live-tracking world.

Hex code vs registration vs callsign
Three identifiers travel with a flight, and the hex code is the one people most often confuse with the others:
- ICAO 24-bit / hex code (
40621D) — the machine address in the transponder, tied to the airframe. This is what you receive from an ADS-B feed. - Registration / tail number (
G-STBC) — the human-readable identifier painted on the aircraft, also tied to the airframe but meant for people. (We cover it in depth in Tail Number Lookup.) - Callsign (
BAW123) — tied to the flight, not the aircraft; it changes every time the airframe flies a different route.
The hex code and the registration both identify the same physical aircraft, so a good aircraft registry lets you convert between them — which is exactly what you need to turn a stream of hex codes into human-readable flight cards.
The address is structured by country
The 24-bit space isn't handed out randomly. ICAO allocates blocks of addresses to each country, so the high bits of the hex code encode the aircraft's country of registration — the equivalent of the country prefix on a tail number, one layer down. A few examples of where blocks begin:
A00000–AFFFFF— United States (the largest block, matching the size of the US register)400000–43FFFF— United Kingdom3C0000–3FFFFF— Germany7C0000–7FFFFF— Australia
So a hex code starting with A is almost certainly a US aircraft, and 40–43 is British. You don't have to decode this by hand, but it's why the codes cluster the way they do — and why a lookup service can sanity-check an address against a country.

Resolving a hex code by API
SkyLink API's aircraft lookup endpoint takes an ICAO24 hex address and returns the aircraft's registration, type, and operator from a registry of 615,000+ records:
curl "https://skylink-api.p.rapidapi.com/aircraft/icao24/40621D" \
-H "X-RapidAPI-Key: $RAPIDAPI_KEY" \
-H "X-RapidAPI-Host: skylink-api.p.rapidapi.com"{
"query": "40621D",
"found": true,
"aircraft": {
"registration": "G-STBC",
"icao24": "40621D",
"icao_type": "B77W",
"type_name": "BOEING 777-36NER",
"owner_operator": "British Airways"
}
}Three things to build in from the start:
- Case and leading zeros. The address is accepted in lowercase or uppercase, and leading zeros are significant —
0A0022is a valid address and must not be trimmed toA0022. Normalize to a consistent case, but never strip zeros. found: falseis not an error. An unmatched address returns HTTP 200 with"found": falseand"aircraft": null, not a 404 — check thefoundboolean rather than the status code.- Turn off photos on the hot path. Pass
photos=falsewhen enriching a whole feed of hex codes; thumbnails add latency you don't want on a map overlay.
Enriching a live feed
The same hex address is the filter key on the live ADS-B endpoint, so a typical pipeline is: read positions off the feed, then resolve each unfamiliar hex code once and cache it (airframe metadata effectively never changes). You can even go the other way — filter the live feed by a known hex code to follow one specific aircraft:
curl "https://skylink-api.p.rapidapi.com/adsb/aircraft?icao24=0A0022" \
-H "X-RapidAPI-Key: $RAPIDAPI_KEY" \
-H "X-RapidAPI-Host: skylink-api.p.rapidapi.com"Because the hex code is the airframe's stable machine identity, it's the ideal primary key for a tracking database: positions come and go, callsigns change daily, but the ICAO24 address stays with the aircraft for its life on the register. Resolve it against the registry once and you can label every position report with a tail number, type, and operator.
SkyLink API gives you a free tier of 1,000 requests/month to test ICAO24 and live-feed lookups against, with paid plans starting at $18.59/mo for production traffic. It's available through the free trial — sign up, grab a key, and turn Mode S hex codes into full aircraft data in one call.
