ISO 8583 Parser
Free ยท Hands-on guide ยท ~9 min read ยท Updated 2026-08-12

ISO 8583 Bitmap Explained: Decode and Build It by Hand

The bitmap is the table of contents of every ISO 8583 message: 8 or 16 bytes that announce exactly which data elements follow. After this page you can take any hex bitmap and list its fields on paper โ€” no tool required โ€” and go the other way, turning a field list into the exact hex string. The only equipment you need is the one small hex-to-binary table below.

The three rules

Everything on this page follows from three facts:

  1. One hex character is four bits. The primary bitmap is 16 hex characters = 64 bits = 8 bytes.
  2. Bits are numbered 1 to 64, left to right. Not 0 to 63. Programmers instinctively count from 0, and that off-by-one produces a field list that is entirely wrong by one โ€” the single most common bitmap mistake.
  3. Bit N set means data element N is present โ€” with one exception: bit 1 doesn't announce a data element, it announces that a second bitmap follows.

Keep this conversion table next to you; it is the only lookup the whole procedure needs:

HexBinaryHexBinary
0000081000
1000191001
20010A1010
30011B1011
40100C1100
50101D1101
60110E1110
70111F1111

Hex โ†’ field numbers, step by step

Take a real bitmap and walk it end to end:

7238400108C08000

The procedure:

  1. Write the 16 hex characters in a row.
  2. Under each character, write its 4-bit binary from the table above.
  3. Number the bit positions 1, 2, 3 โ€ฆ 64 from the left.
  4. Every position holding a 1 is a present field.

A shortcut that saves counting: hex character k covers bits 4(kโˆ’1)+1 through 4k. Character 1 covers bits 1โ€“4, character 2 covers 5โ€“8, character 11 covers 41โ€“44, and so on. Here is the full walk:

Char #HexBinaryBits coveredFields set
1701111โ€“42, 3, 4 (bit 1 = 0 โ†’ no secondary bitmap)
2200105โ€“87
3300119โ€“1211, 12
48100013โ€“1613
54010017โ€“2018
60000021โ€“24โ€”
70000025โ€“28โ€”
81000129โ€“3232
90000033โ€“36โ€”
108100037โ€“4037
11C110041โ€“4441, 42
120000045โ€“48โ€”
138100049โ€“5249
140000053โ€“56โ€”
150000057โ€“60โ€”
160000061โ€“64โ€”

Result: fields 2, 3, 4, 7, 11, 12, 13, 18, 32, 37, 41, 42, 49 โ€” the shape of a typical authorization: PAN, processing code, amount, timestamp, STAN, times and dates, acquirer ID, RRN, terminal and merchant IDs, currency. What each of those numbers means is in the field quick reference; paste the same hex into the bitmap calculator and it draws all 64 bits so you can check your paper work bit by bit.

Two things to remember once the field list is in hand: the data elements follow in ascending field number order, and each element then has its own length rules (fixed, LLVAR, LLLVAR) โ€” that layer is covered in reading field format notation.

Field numbers โ†’ hex, one byte at a time

Going the other way is easier if you stop thinking in 64 bits and start thinking in 8 bytes of 8 fields each:

Byte12345678
Owns fields1โ€“89โ€“1617โ€“2425โ€“3233โ€“4041โ€“4849โ€“5657โ€“64

For any field N: byte number = โŒˆN/8โŒ‰, and its position inside that byte = ((Nโˆ’1) mod 8) + 1, counting from the left. Each position has a fixed hex weight โ€” the byte's value is just the sum of the weights of the fields you set:

Position in byte12345678
Hex weight8040201008040201

Worked example โ€” build the bitmap for fields 2, 3, 4, 11, 41:

ByteOwns fieldsPresent hereBit patternHex
11โ€“82, 3, 40111000070 (40+20+10)
29โ€“1611 โ†’ position 30010000020
317โ€“24โ€”0000000000
425โ€“32โ€”0000000000
533โ€“40โ€”0000000000
641โ€“4841 โ†’ position 11000000080
749โ€“56โ€”0000000000
857โ€“64โ€”0000000000

Read the hex column top to bottom:

7020000000800000

Spot-check the two non-obvious fields: field 11 โ†’ byte โŒˆ11/8โŒ‰ = 2, position (11โˆ’1) mod 8 + 1 = 3, weight 20. Field 41 โ†’ byte โŒˆ41/8โŒ‰ = 6, position (41โˆ’1) mod 8 + 1 = 1, weight 80. Type 2,3,4,11,41 into the calculator's fields box and the same hex comes back.

The secondary bitmap: what bit 1 really means

Bit 1 is not "DE1 is present". Bit 1 set means another 8-byte bitmap immediately follows the first one, and that second bitmap covers fields 65โ€“128. DE1 is the secondary bitmap โ€” it never appears as a data element in a parsed message, which is why no correct decoder ever lists "field 1" in its output.

Decoding the second bitmap uses exactly the same procedure, then add 64: position 1 of the secondary bitmap = field 65, position 6 = field 70, position 64 = field 128.

Here is the smallest real message that needs one โ€” a network echo test (0800), the same message dissected in real message examples:

8220000000000000 0400000000000000
PieceHexBinaryMeaning
Primary, char 181000Bit 1 set โ†’ a secondary bitmap follows
Primary, char 220010Bit 7 โ†’ DE7 (transmission date & time)
Primary, char 320010Bit 11 โ†’ DE11 (STAN)
Secondary, byte 10400000100Position 6 โ†’ 64 + 6 = DE70 (network mgmt code)

Fields present: 7, 11, 70. Because DE70 sits above 64, even this tiny three-field message must carry 16 bytes of bitmap. Open the full 0800 in the parser โ†’

Mistake 1: reading data as a secondary bitmap

Sixteen bytes of hex in front of you does not mean sixteen bytes of bitmap. The first bit decides. Take the opening of the 0100 authorization from the examples article โ€” bitmap plus the first 16 characters of data:

723C448028C08000 1640000012345678

The first character is 7 = 0111 โ€” bit 1 is clear, so the bitmap ends after 16 characters. What follows (16 then 4000001234โ€ฆ) is DE2: an LLVAR length of 16 and the start of the PAN. Force those 16 characters through the bitmap procedure anyway and you "discover" fields 68, 70, 71, 74, 100, 103, 107, 108, 110, 114, 116, 118, 119, 122, 123, 124, 125 โ€” seventeen phantom fields that were never sent, and every real field after DE2 lands in the wrong place.

The warning sign is exactly that pattern: a scatter of high-numbered, rarely-used fields in an otherwise ordinary message. Paste the full 32 characters into the bitmap calculator and it flags it: bit 1 is 0, so the last 16 characters are not bitmap and get ignored.

Mistake 2: using fields 65โ€“128 without setting bit 1

The mirror image, on the build side. Say the message needs DE90 (original data elements, used in reversals) on top of fields 2, 3, 4, 11, 41. It is not enough to append a second bitmap with position 26 set โ€” bit 1 must come on too, which changes the very first byte:

BitmapWhat a receiver does
CorrectF020000000800000 0000004000000000First char F = 1111: bit 1 on โ†’ reads 16 bytes, finds 2, 3, 4, 11, 41, 90
Bit 1 forgotten7020000000800000 0000004000000000First char 7: bit 1 off โ†’ reads only 8 bytes, then parses 0000004000โ€ฆ as the start of DE2 โ€” every field from there on is garbage

Note the first byte: 70 became F0 because the bit-1 weight (80) was added. The receiving side won't reject the broken version as "bad bitmap" โ€” it will fail later, deep inside the data, with a confusing length or format error. The calculator guards both directions: enter any field above 64 in the fields box and it sets bit 1 for you; paste a 16-character bitmap whose first character is 8 or higher and it warns that the secondary bitmap is missing.

Sanity checks you can do at a glance

Why a bitmap at all

ISO 8583 defines up to 128 data elements, but a typical message carries only 10โ€“20 of them. A fixed layout would force every message to reserve space for all 128 โ€” hundreds of wasted bytes per transaction, multiplied by billions of transactions. The bitmap spends 8 bytes (16 when fields above 64 are needed) to say "only these fields follow", so each message carries exactly what it needs, and a receiver can test "is DE55 present?" by checking a single bit before parsing anything. How the bitmap sits between the MTI and the data elements is laid out in how to read an ISO 8583 message.


๐Ÿ‘‰ Prefer to see the bits drawn instead of drawing them? The bitmap calculator works both directions โ€” hex to fields and fields to hex โ€” and to watch a bitmap doing its job inside a full message, paste one of the real examples into the parser.

Read next