Super Mario Bros. 2

Untested

NES · 1988 · Platformer · Decompilation

Pull up vegetables and throw them at Shyguys across seven dream worlds.

▶ Play with your filesYou supply your own Super Mario Bros. 2 (USA) (Rev 1) ROM; it is read in the browser and never uploaded. ROM body sha1 ff5bcacf7417b4de1c49f9e54c2905d91391455b (262,144 bytes; a 16-byte iNES or NES 2.0 header on top is fine). The earlier (USA) revision and Super Mario USA (Japan) are recognised and will run too.
Controls
Arrow keysmove, duck, climb
XA (jump)
ZB (run, pick up, throw)
EnterStart
ShiftSelect
Gamepadsupported through EmulatorJS

About this build

Super Mario Bros. 2 reassembled byte-for-byte from the Xkeeper0 disassembly and run in the browser. The project ships only 6502 source and a loader page: you supply your own cartridge dump, which is read in the page and never uploaded. The build reproduces the (USA) (Rev 1) ROM body exactly — 0 of 262,144 bytes differ — and can also produce the earlier US revision and the Japanese Super Mario USA.

Built from
The Xkeeper0 6502 disassembly, reassembled with asm6f, run on EmulatorJS 4.2.3 with the libretro fceumm core (nestopia selectable).
Type
Decompilation
Game files
You supply your own Super Mario Bros. 2 (USA) (Rev 1) ROM; it is read in the browser and never uploaded. ROM body sha1 ff5bcacf7417b4de1c49f9e54c2905d91391455b (262,144 bytes; a 16-byte iNES or NES 2.0 header on top is fine). The earlier (USA) revision and Super Mario USA (Japan) are recognised and will run too.
Code licence
The upstream disassembly carries no licence file. The vendored EmulatorJS is GPL-3.0 and the libretro fceumm and nestopia cores are GPL-2.0.
Assets
No game assets are distributed. Super Mario Bros. 2 is © Nintendo.
Source
Xkeeper0/smb2 ↗

What has been tested

Reassembly byte-matches the (USA) (Rev 1) ROM body (0 of 262,144 bytes differ; the 3 differing file bytes are all iNES vs NES 2.0 header). In the browser: boots from a user-picked ROM with zero off-site requests, reaches actual level play rather than the character-select screen (StackArea = $C0), and the controller demonstrably drives the player — from one save state, holding Right and holding Left move PlayerX in opposite directions from byte-identical work RAM. A save state survives a page reload with position, hearts and lives intact. All runs muted.

Last tested 2026-10-05 in Chrome (headless, Linux). Full playthrough: not verified. How games are tested.

Known limitations

Saves

The cartridge has no battery, so there is nothing for the game itself to save. The page keeps an automatic save state in this browser's storage, keyed by your ROM's SHA-1, written every 15 seconds and when you leave the page, and restores it next time. Clearing site data removes it; there is a button in the footer to discard it.

Play next