Microsoft has not published the Jet and ACE file formats. This page follows the
HACKING.md notes of the MDB Tools project, which come from reverse
engineering; parts are marked unknown there and here. Offsets are hexadecimal and
numbers little-endian. “Jet 3” is Access 97; “Jet 4” is Access 2000 to 2003, and the
ACE files of Access 2007 and later use the Jet 4 layouts with additions.
Database definition page
Pages are 2,048 bytes in Jet 3 and 4,096 in Jet 4 and ACE. Page 0 describes the database.
| Offset | Size | Field |
|---|---|---|
00 | 1 | Page type 00. |
04 | 15 | Standard Jet DB (.mdb), Standard ACE DB (.accdb), or MSISAM Database (Microsoft Money). |
14 | 1 | Format: 00 Jet 3, 01 Jet 4, 02 Access 2007, 03 Access 2010, 04 Access 2013 (none seen), 05 Access 2016, 06 Access 2019 and 2021. |
15 | 1 | Sub-version, 0 or 1 (seen with formats 3 and 4). |
16 | 2 | Unused, zero. |
18 | 126 or 128 | Region masked with RC4 using a fixed key (126 bytes in Jet 3, 128 in Jet 4). The fields below are inside it. |
38 | 1 | Jet 3: a flag byte, 0 or 1. |
3A | 2 | Jet 3: default sort order. |
3C | 2 | Default code page (1252 in every Jet 3 file examined). |
3E | 4 | Database key: when not zero, every page is RC4-encrypted with this key XORed with the page number. |
42 | 20 or 40 | Database password (Jet 3: 20 bytes, Jet 4: 40), masked. |
6A | 4 | Jet 4: build number of the engine that made the file. |
6E | 4 | Jet 4: default sort order. |
72 | 8 | Jet 4: creation date, also used to mask the password. |
299 | 2 | Access 2007 and later: length of an Office encryption structure, for files encrypted with a password (not decoded by MDB Tools). |
Notes from HACKING.md, read 2026-11-13: Access does not initialise pages to zero before
writing them, so files hold a lot of uninitialised data. The format byte at 14
is what MDB Tools’ mdb-ver reads; the sub-version at 15 is tested by
Access only for codes 3 and 4. Together they are a two-level forward-compatibility gate that is raised by
what the database holds and never lowered: 02 00 nothing past Access 2007;
03 00 a feature that Access 2007 SP2 opens read-only for that object (such as a
calculated column); 03 01 a feature that Access 2007 SP2 must refuse (an Access 2010
sort order, Access 2010 encryption, or publication to Access Services). The other two version
bytes have only been seen as zero. The password has an extra mask in Jet 4 derived from the creation
date. Money (MSISAM Database) files use their own encryption. In Jet 3 and Jet 4 each
encrypted page uses RC4 keyed by the database key XOR the page number; Access 2007 and later use
Office encryption (RC4 CryptoAPI or AES) keyed by the password, described by a structure whose 2-byte
length is at 299, which MDB Tools does not support. In Jet 4 the default code page
still reads 1252 although text is Unicode there. The build number at 6A is 0 in
Jet 3; in 1,337 files from the web it took 20 values: 2927, 3714, 4431, 6218, 8015, 8618
(Jet 4.0 SP3 to SP8), 9025, 9511, 9635, 9704, 9756, 9765, 9801 (later Jet 4.0 updates; 9801 is
msjet40.dll 4.0.9801), 4214 (pre-release Access 2007) and 4518 (Access 2007 and every
later ACE release, so it only says “ACE” for newer files); it is informational only. The Jet 3
byte at 38 reads 0 or 1 once unmasked (a hex dump shows 63 for 0 and
62 for 1); each column descriptor of a Jet 3 file repeats it in its own
file_flag. It marks which of two writers made the structure, with 1 for tables and
columns made last; MDB Tools could not establish which writers, and no file with 1 holds an object
made before October 2000 (so 0 for Jet 3.5 and 1 for Jet 4.0 or later fits, unproven).
Page 1 holds the global page usage map. The system table MSysObjects,
whose table definition is always at page 2, lists every table, query, form and
report.
Page types
| First byte | Page |
|---|---|
00 | Database definition (page 0 only) |
01 | Data |
02 | Table definition (TDEF); see table definitions |
03 | Intermediate index |
04 | Leaf index |
05 | Page usage bitmap |
08 | Unknown; listed with a question mark |
Data pages
| Jet 3 | Jet 4 | Size | Field |
|---|---|---|---|
00 | 00 | 1 | Page type 01. |
01 | 01 | 1 | Always 1. |
02 | 02 | 2 | Free space on the page. |
04 | 04 | 4 | Page of the table definition the rows belong to. |
| – | 08 | 4 | Jet 4: write time stamp. |
08 | 0C | 2 | Number of rows. |
0A | 0E | 2 each | Row offset table. |
Rows are stored from the end of the page backwards; each row runs from its offset to
the byte before the previous row’s. In a row offset the low 13 bits
(1FFF) are the offset; 4000 means the slot holds a 4-byte
pointer to the row on another page (an overflow row); 8000 means
deleted; 2000 has not been seen. The Jet 4 write stamp is the
GetTickCount() value (machine uptime in milliseconds) when the page was written;
Access’s page initialiser sets it to 0 and the write path fills it in, so most pages carry
zero, and no reader of it is known. The overflow pointer has the same layout as a memo’s
data pointer (row number in the low byte, page number in the upper three); the relocated row on
the overflow page has the 80 flag set, so it is reached only through the pointer and is not
read again when the overflow page is scanned. A row can be both deleted and an overflow pointer.
Decoding a row needs the number and types of columns from its TDEF page.
Row layout
| Field | Jet 3 | Jet 4 |
|---|---|---|
| Number of columns | 1 byte | 2 bytes |
| Fixed-length columns | At the offsets in the column definitions | |
| Variable-length columns | One after another | |
| End-of-data offset | 1 byte | 2 bytes |
| Variable column offsets | 1 byte each | 2 bytes each |
| Jump table | For rows of 256 bytes and more: the first variable column in each 256-byte stretch | None |
| Number of variable columns | 1 byte | 2 bytes |
| Null mask | (columns + 7) / 8 bytes; bit clear means null. Boolean columns are stored only here. | |
The row is read from both ends: the counts and offset table at the end, written backwards, say where each variable column starts.
- A row always has the number of fixed columns the table definition gives, but may have fewer variable columns, because rows are not updated when columns are added.
- The fixed columns come first to last, then the non-null variable columns first to last. If the definition has no variable columns, the row holds only the column count, the fixed columns and the null mask.
var_lenis the number of entries in the variable offset table;var_table[]and the jump table are stored in reverse order. The end-of-data field points at the first byte after the variable columns and fixes where the last one ends.- Fixed columns can be null. In the null mask there is one bit per column, from the least significant bit of the first byte, 0 meaning null and 1 not null. Boolean columns hold their value in the mask: 0 false, 1 true.
- Jet 3 jump table: offsets are one byte, so for rows of 256 bytes or more the
table holds the number of the first column in each 256-byte segment; the end-of-data field counts
as one more entry of the variable offset table. Example: with 45 columns, if the 15th column is the
first at offset 256 or more, the first entry is
0E(14); if the 24th is the first at 512 or more, the next is17(23); if the end-of-data field is the first at 768 or more the last is2D(45). The number of entries follows from the row size, not from where the end-of-data field is, so there can be a dummy entryFF: the example’s table is2D 17 0E FFas stored. Jet 4 has no jump table. - A deleted fixed column keeps its offset in the definition, and columns are never really removed
from rows: the column stays and is null in new rows. A row may have fewer than
max_colscolumns but never more;max_colsis never decremented (a 6-column table with one column deleted and one added has 7).
Memo and OLE values
Long text (memo) and long binary (OLE) columns hold a 12-byte header in the row:
| Offset | Size | Field |
|---|---|---|
00 | 4 | Length in the low 30 bits; the top two bits are the type: 80 the value follows inline in the row; 40 it is a single row on an LVAL page; 00 it is spread over a chain of LVAL pages. |
04 | 4 | Where the value is: row number in the low byte, page number in the upper three. |
08 | 4 | Write stamp; zero for inline values. |
LVAL pages have a data page header with the text LVAL where the
table definition page would be. In a chain, each part starts with a 4-byte pointer
to the next. A page holds 2,032 (Jet 3) or 4,076 (Jet 4) bytes of value: the page minus the 10-
or 14-byte data page header, a 2-byte row offset and the 4-byte next-page pointer. The
largest value is 0x3FFFFFFF bytes, the 1 GB of the Access specifications. The four bytes after
LVAL in an LVAL page header are the same write stamp as on a data page.
- Type
80: the value is inline, thememo_lenbytes after the 12-byte header; the pointer and the stamp are zero. - Type
40(record type 1 on an LVAL page): the row is the value itself. Its start is the row offset atrow_id(masked with1FFF); its end is the previous row’s offset, or the page size (2,048 or 4,096) forrow_id0. - Type
00(record type 2): each row starts with a 4-byte pointer to the next LVAL page (0 at the end) followed by a part of the value. - If a memo column is marked for compression, only a value of at most 1,024 characters when uncompressed can be compressed; longer ones must be stored uncompressed.
Page usage maps
- Type 0: byte 0 is
00, bytes 1 to 4 the first page covered, then a bitmap, one bit per page from the least significant bit; a set bit means the page belongs to the table. - Type 1: byte 0 is
01, then 4-byte pointers to usage map pages (type05), each holding the same kind of bitmap after a 4-byte header (05 01 00 00).
There are three uses: the global map on page 1, which tracks allocated pages in the whole
database, and two maps per table, one of the pages the table owns and one of those with free space
(used for inserts). The table maps have a fixed size, 128 bytes (Jet 3) and 64 bytes (Jet 4). A
type 0 map covers at most 128 × 8 × 2,048 or 64 × 8 × 4,096 bytes, about 2 MB, so for larger files a
type 1 map is an indirection list; its first start-page field is reused, giving 33 (Jet 3) or 17
(Jet 4) pointers per row. Each type 05 page (05, 01, two
zero bytes) then holds a bitmap with the same bit order for 2,044 × 8 = 16,352 (Jet 3) or
4,092 × 8 = 32,736 (Jet 4) pages, so the maximum database sizes (about 1,053 MB and 2,173 MB) are
covered and, MDB Tools says, no other scheme is believed to exist.
Text
Jet 3 text is in the database’s code page. Jet 4 and ACE text is UCS-2 (UTF-16LE),
but may be compressed: a value starting with FF FE begins in compressed
mode, where each character whose high byte is 0 is stored as one byte; a
00 byte switches between compressed and normal mode. Writers compress
only when it makes the value shorter; a value that contains any character of the form
0xXX00 cannot be compressed, and the string may end in either mode. In Jet 3
the code page is that of the machine that created the file, recorded at 3C; MDB Tools
defaults to CP1252 and lets the environment variable MDB_JET3_CHARSET override it, and
Windows-1252 leaves 81, 8D, 8F, 90 and
9D undefined, so a file that stores one holds text no Unicode charset round-trips.
MDB Tools returns UTF-8 by default (variable MDBICONV changes it).