Aviation · US registration
N-number to ICAO hex converter.
Turn a US tail number into its Mode S hex code, or a hex code back into a tail number. The method is checked against real FAA Registry values listed below.
Short answer: US N-numbers map to the hex block A00001 to ADF7C7, in a fixed order that skips the letters I and O. N172SP is A12239. The FAA does not publish the formula, so this page proves it against 34 FAA Registry codes instead of asking you to trust it. It says nothing about whether an aircraft is currently registered.
Convert
Result
Enter an N-number such as N172SP, or a hex code such as A12239, and press Convert.
What the Mode S code is
The FAA Registry lists a “Mode S Code” for every US-registered aircraft, written in base 8 (octal) and base 16 (hex). The six-digit hex form, for example A12239 for N172SP, is the 24-bit address people call the ICAO hex or ICAO24. The FAA publishes the code for each registration but, as far as we could find, not the rule that links an N-number to its code. This page therefore does two things: it applies the community-documented layout of the US block, and it shows the evidence that the layout is right.
How the conversion works
The US block holds 915,399 codes, from A00001 to ADF7C7, one for every valid N-number from N1 to N99999 including the letter forms. They are laid out in the order a person would count N-numbers. Each first digit from 1 to 9 owns a block of 101,711 codes. Inside it come 601 slots for the number itself and its letter forms (1 for the number, then each of 24 single letters followed by its 24 two-letter extensions: 1 + 24 × 25 = 601), then ten sub-blocks, one for each possible second digit, of 10,111 codes each. The pattern repeats one level down: a second-digit block is 601 letter slots plus ten third-digit blocks of 951, a third-digit block is 601 plus ten fourth-digit blocks of 35, and a fourth-digit block has just 35 slots, namely the number itself, 24 single letters (no two-letter forms fit at that length) and ten fifth digits. There are 24 letters because the FAA bars I and O (14 CFR 47.15(b)).
To convert, add up the offsets and add them to A00001. To reverse, divide the offset from A00001 by 101,711 to get the first digit, then peel off 601 and divide by 10,111, 951 and 35 in turn until the remainder is a letter slot. The page does exactly this, in your browser, with no lookup.
Worked example
Take N172SP. The 1 is the first digit and adds nothing (its block starts at A00001). The 7 skips the 601-slot letter area and seven blocks of 10,111: 601 + 70,777 = 71,378. The 2 skips 601 and two blocks of 951: 601 + 1,902 = 2,503. The letters SP are the 17th and 14th letters of the 24-letter alphabet, so they add 1 + 16 × 25 for S, then 1 + 13 for P: 415. The total offset is 71,378 + 2,503 + 415 = 74,296. In hex 74,296 is 12238, and A00001 + 12238 = A12239, the code the FAA Registry shows for N172SP, whose octal form is 50221071.
Checked against the FAA Registry
We looked up 34 N-numbers by hand in the FAA N-Number Inquiry on 20 October 2026, chosen to cover every shape: one to five digits, one letter, two letters, and numbers at both ends of the block. For 19 of them the registry shows both hex and octal; for the other 15 (including N1 and N99999) it shows only the octal Mode S code. The converter matched the registry on all 34, and converted each hex code back to the same N-number. Separately, a test converts all 915,399 possible N-numbers, checks that no two share a code, that the lowest is A00001 and the highest ADF7C7, and that every code converts back to its N-number. A sample:
| N-number | FAA Registry hex | Same code in octal |
|---|---|---|
| N1A | A00002 | 50000002 |
| N100 | A004B3 | 50002263 |
| N12AB | A0515B | 50050533 |
| N172SP | A12239 | 50221071 |
| N5ZZ | A63795 | 51433625 |
| N737AA | A9E50D | 52362415 |
| N777 | AA8307 | 52501407 |
| N9999A | ADF7A6 | 53373646 |
Hex is as printed by the registry. Octal is the same number in base 8, which the registry also prints; the two agreed wherever we compared them.
Mistakes and edge cases
- Invalid shapes. N0, an I or O, a letter in the middle (N1A2), three letters (N12ABC) or a zero straight after N are all refused with a reason, following 14 CFR 47.15(b).
- Valid is not an aircraft. A well-formed N-number converts to a code whether or not an aircraft holds it. The registry lists N99999, for example, as a reserved number, not as an aircraft.
- Hex outside the block. A code below A00001 or above ADF7C7 is reported as not an N-number rather than forced into one.
- Squawk is not hex. The four-digit squawk code a controller assigns is unrelated to the 24-bit address. See the squawk codes reference.
- Case and spacing. “n 172-sp” and “N172SP” are the same input.
Who this is for
ADS-B and flight-tracking hobbyists who see a hex code and want the tail number, or have a tail number and want to filter a feed, developers cross-checking a data pipeline, and students curious how a registration number maps to a transponder address.
What this does not cover
- Whether a number is registered, who owns it, or what aircraft it is. Use the FAA Registry’s N-Number Inquiry.
- Any country other than the United States, and US military or other allocations outside the N-number block.
- What a given transponder is actually broadcasting. This page knows only the registry’s code, not what any aircraft’s equipment is set to send.
- How the FAA assigns codes when a registration changes. We found no FAA statement on that, so we make none.
Frequently asked questions
How do I convert an N-number to an ICAO hex code?
Type the N-number into the converter and press Convert. It returns the six-digit hex Mode S code, plus the decimal and octal forms. For example N172SP gives A12239, the value the FAA Registry shows for that registration. The reverse box turns a hex code in the US block back into an N-number.
Is there an official FAA formula for N-number to Mode S hex?
We found no FAA document that states the formula. The FAA Registry publishes the code for each registration, and the arithmetic used here is the community-documented layout of the US block. We trust it only because it reproduces all 34 registry codes we checked by hand, and because every one of the 915,399 possible N-numbers converts and converts back uniquely.
What range of hex codes do N-numbers use?
By this mapping the US block runs from A00001 (N1) to ADF7C7 (N99999). The registry confirms both ends: N1 is 50000001 in octal (A00001) and N99999 is 53373707 (ADF7C7). Every other code we checked falls between them. Codes outside it belong to other countries or to uses this page does not cover.
Why are the letters I and O never used in an N-number?
FAA rule 14 CFR 47.15(b) says the letters I and O may not be used. That leaves 24 letters, which is why the layout counts letters in blocks of 24 and why the converter rejects any N-number that contains an I or an O.
What does an N-number look like, exactly?
After the N there are at most five characters: all numbers, or one to four numbers and one suffix letter, or one to three numbers and two suffix letters (14 CFR 47.15(b)). The first character after N is never zero. N172SP, N10000, N1000A and N100AB are valid shapes; N1234AB is not.
Does a converted code prove the aircraft is registered?
No. The converter works on the shape of the number. There are 915,399 valid shapes and far fewer registered aircraft, so a code can be perfectly valid and belong to no current registration. Use the FAA Registry’s N-Number Inquiry for the real record.
Why does the FAA Registry also show an octal code?
The registry lists the same Mode S code in base 8 and base 16. For N172SP it shows 50221071 in octal and A12239 in hex, and this page shows both so you can match whichever your source uses.
Does this work for aircraft outside the United States?
No. Other countries hold other blocks of 24-bit addresses and use other registration marks, and this page converts only the US N-number block. A hex code outside A00001 to ADF7C7 is reported as not an N-number.
Sources
Retrieved
A converter, not a registry lookup
This page converts the shape of an N-number using a documented layout and does not query the FAA or confirm that any aircraft exists. The FAA publishes no formula, so for anything that matters, check the code in the FAA Registry. TNAADO is not affiliated with the FAA.