NDEF (NFC Data Exchange Format) — NFC Forum binary message format for encapsulating application payloads. Each NDEF message is a sequence of NDEF Records.
Record Structure
| Byte Offset | Field | Description |
| 0 | Flags (1 byte) | Bit 7=MB, Bit 6=ME, Bit 5=CF, Bit 4=SR, Bit 3=IL, Bits 0-2=TNF |
| 1 | TYPE LENGTH | Unsigned 8-bit, length of TYPE field |
| 2-5 | PAYLOAD LENGTH | 1 byte if SR=1, 4 bytes (big-endian) if SR=0 |
| var | ID LENGTH | Present only if IL=1. Length of ID field |
| var | TYPE | Record type identifier |
| var | ID | Optional record identifier |
| var | PAYLOAD | Application data |
TNF Values
| TNF | Name | Type Format | Common Use |
| 0x00 | Empty | — | Message terminator |
| 0x01 | NFC Forum Well-Known Type | NFC RTD | Text (T), URI (U), Smart Poster (Sp), Handover (Hc/Hr/Hs), Signature (Sig) |
| 0x02 | MIME Media Type | RFC 2046 | text/plain, application/json, image/png |
| 0x03 | Absolute URI | RFC 3986 | Full URI stored in TYPE field |
| 0x04 | NFC Forum External Type | urn:nfc:ext: | Vendor-specific: contoso.com:myapp |
| 0x05 | Unknown | — | Opaque payload |
| 0x06 | Unchanged | — | Chunk continuation (middle/terminating) |
Well-Known Type Payloads
Text Record (T / 0x54)
StatusByte | LanguageCode | TextData(UTF-8 or UTF-16)
StatusByte: Bit 7 = UTF-16 if 1, UTF-8 if 0; Bits 5-0 = lang code length
URI Record (U / 0x55)
URI Identifier Code (1 byte) | URI Field (UTF-8)
Abbreviation codes: 0x01=http://www. 0x04=https:// 0x05=tel: 0x06=mailto:
Smart Poster (Sp)
Nested NDEF message containing: URI record (mandatory) + optional Title(Text), Icon(MIME), Type, Size, Action records
NFC Forum Tag Type Capacities
| Tag Type | Standard | Memory | Max NDEF Size |
| Type 1 (Topaz) | ISO 14443-3A | 96 B – 2 KB | ~90 B – 2 KB |
| Type 2 (NTAG203) | ISO 14443-3A | 48 B – 2 KB | ~40 B – 2 KB |
| Type 3 (FeliCa) | JIS X 6319-4 | 2 KB | ~2 KB |
| Type 4 (DESFire) | ISO 14443-4 | Up to 32 KB | ~32 KB |
| Type 5 (ISO 15693) | ISO 15693 | Up to 64 KB | ~64 KB |
| NTAG213/215/216 | ISO 14443-3A (Type 2) | 144/504/888 B | ~137/496/880 B |