Standard header

The following table shows the standard contents of the ROM header. Most of the structure of the header is defined by the IPL3 routines commonly used in commercial games (which are actually contained in the ROM itself); only a few fields are accessed by IPL2 (which is burned in PIF ROM) and are thus hard-coded for all possible valid N64 ROMs.

Offset Bytes Name Description
0x00 4 PI DOM1 configura flags These flags are used by IPL2 to configure access to the ROM (which is mapped in the PI DOM1 space, see memory map). IPL2 first configure the PI to its slowest speed to be able to read these 4 bytes, and then use them to configure the correct speed to access the ROM.


All known commercial games use 0x80 0x37 0x12 0x40 in these bytes.


These fields could be tuned in replica cartridges to adapt to the actual maximum physical speed that the ROM can be accessed, but please pay attention that many emulators expect to find the 4 "standard" values here and actually use them as a "fixed ID" to detect if the ROM dump was byte-swapped.

0x04 4 Clock override(?) Usually 0
0x08 4 Initial PC Initial PC in RDRAM. IPL3 will jump to this address when it has finished initializing the hardware, to boot the ROM.


The IPL3 for CIC 6103 behaves differently: the value stored here is subtracted by 0x100000 before the jump. For instance, Paper Mario (a game with CIC 6103) contains the value 0x80125C00 in this field, but the actual entry point is 0x80025C00.

0x0C 4 ? ?
0x10 8 CRC Checksum calculated on 1 Mbyte of ROM contents starting from offset 0x1000 (after IPL3). This checksum is computed with a custom algorithm implemented by IPL3 that verifies the integrity of the ROM before booting it. If the checksum fails, IPL3 refuses to boot the ROM and hangs the console.


To see the exact algorithm used by IPL3, see the source code of the chksum64 tool shipped with libdragon.

0x18 8 ? ?
0x20 20 Game name ASCII string that contains the name of the game. Padding Is usually performed with 0x20 (ASCII space).
0x34 7 Unused
0x3B 1 Media format An ASCII character identifying the physical support that this ROM was extracted from.
N Standard gamepad (cartridge)
D 64DD disk
C Expandable game: cartridge part
E Expandable game: 64DD disk part
Z Aleck64 cart
0x3C 2 Game ID Two letter code to identify the game. Normally, these are ASCII uppercase letters.
0x3E 1 Country code An ASCII character that specifies the country this ROM is intended for.
7 Beta G Gateway 64 (NTSC) P European
A Asian H Dutch S Spanish
B Brazilian I Italian U Australian
C Chinese J Japanese W Scandinavian
D German K Korean X European
E North America L Gateway 64 (PAL) Y European
F French N Canadian


0x3F 1 Unused
0x40 4032 IPL3 This area contains the IPL3 boot code. Each ROM ships its own IPL3 that is meant to work together with the CIC installed in the ROM. Before running IPL3, IPL2 checks its checksum also using a seed coming from the CIC, which binds each IPL3 code to a specific version of CIC.

Advanced Homebrew ROM Header

The Advanced Homebrew ROM Header format is a convention that has been agreed upon in the N64 homebrew community to add additional information in the header, using unused fields. The goal of this convention is to let homebrew ROMs declare the correct saveype and controllers that are expected to play the game. The format has been introduced by the EverDrive 64 flashcard and has been later enhanced by the homebrew community.

This is useful because emulators normally work using a game database which matches games using checksum to find out which savetype and controllers are expected by the game, to help gamers play the game. For instance, when a N64 emulator detects that a Perfect Dark ROM is loaded, it will automatically emulate a 16Kb EEPROM to save the game (that was the original support present in the physical cartridge for the original game), and will possibly also emulate a preinstalled Transfer PAK, as the accessory can be used with the game. This is done purely by matching the Perfect Dark ROM checksum in a database, so a homebrew game, which would probably not be present in game databases, would suffer from non-working saves and possibly wouldn't be able to use special controllers or accessories.

Instead, by using the Advanced Hombrew ROM Header, emulators can automatically configure the required emulated hardware as expected without having to keep any additional database, by simply decoding specific fields of the ROM header. In addition to emulators, also development flashcarts and loaders can use this format to automatically configure the correct savetype when the ROM is loaded.

Homebrew ROM Header special flags

Offset Bytes Name Description
0x36 1 Controller 1 This byte contains the suggested / expected controller hardware that should be attached to port 1.

Values 0x01-0x7F indicate a standard N64 controller, possibly with some installed pak.

Values 0x80-0xFE indicate a different kind of controller.

0x00 No information provided.

Emulators should follow their standard configuration for this port.

0x80 N64 mouse
0x01 N64 controller with Rumble Pak 0x81 VRU
0x02 N64 controller with Controller Pak 0x82 Gamecube controller
0x03 N64 controller with Transfer Pak 0x83 Randnet keyboard
0xFF Nothing attached to this port 0x84 Gamecube keyboard


0x37 1 Controller 2 This byte contains the suggested / expected controller hardware that should be attached to port 2. See byte 0x36 for more information.
0x38 1 Controller 3 This byte contains the suggested / expected controller hardware that should be attached to port 3. See byte 0x36 for more information.
0x39 1 Controller 4 This byte contains the suggested / expected controller hardware that should be attached to port 4. See byte 0x36 for more information.
0x3C 2 Game ID This must contain the ASCII characters "ED". It is used as an ID to identify that the Advanced Homebrew ROM header format Is being used by this ROM.
0x3F 1 Savetype This byte mostly contains information on the savetype. It must be decoded as a bitfield:
Bit Description
0 The game uses the serial RTC (via Joybus)
1 The game is region-free
2 Unused
3 Unused
4-7 Savetype expected by the game. possibile values:


0: None

1: 4K EEPROM

2: 16K EEPROM

3: 256K SRAM

4: 768K SRAM (banked)

5: Flash RAM

6: 1M SRAM

Support by emulators

Emulators not listed here do not support the advanced homebrew ROM header format.

Emulator Current support
Ares Supports Savetype only
cen64 Supports Savetype only

Support by flashcarts

Support by flashcarts can vary depending on the USB loader being used and/or the flashcart operating system. Notice that flashcarts can emulate a specific savetype but have nothing to do with controllers, so the maximum expected support is related to savetype.

Flashcart Loader Current support
64drive 64drive official C tool None
64drive menu None
g64drive Savetype supported
UNFLoader None
Everdrive 64 Menu Savetype supported
ed64 None
UNFLoader None