BRAINFUCK IN THE BROWSER

A small playground
for Brainfuck.

Brainfuck is a minimal esoteric language created by Urban Müller in 1993.
This page runs a Rust interpreter compiled to WebAssembly. The current program stays in this tab.

Runs locallyNo account and no uploads
Ctrl+↵ to run

main.bf

Ln 1, Col 1 0 instructions
Insert a command

Output

Ready
Program output will appear here.
Choose Run program to execute the current code.
0 bytes

Read by the , command. At end of input, it reads 0.

0 instructions executed0 ms

Memory tape TAPE STATE

Each cell holds one byte, from 0 to 255. The highlighted cell is where the pointer is.

Pointer at cell 0

    Long-running programs pause after 10 million instructions so the page stays responsive. Press Escape to pause a running program.

    THE LANGUAGE

    Eight commands
    and a tape.

    Brainfuck was created by Urban Müller in 1993. A program moves a pointer along a tape of byte cells and uses these eight commands.

    Read more at Esolangs (opens in a new tab).

    To try it+++++. prints one byte. You can also choose the alphabet example and use Step to advance one instruction at a time.

    >
    Move rightMove the pointer to the next cell.
    pointer →
    <
    Move leftMove the pointer to the previous cell.
    ← pointer
    +
    IncrementAdd one to the current cell.
    cell + 1
    -
    DecrementSubtract one from the current cell.
    cell − 1
    .
    OutputWrite the current cell as a byte.
    write
    ,
    InputRead one byte into the current cell.
    read
    [
    Loop startJump past ] if the current cell is zero.
    if 0, jump
    ]
    Loop endJump back to [ if the current cell is not zero.
    if ≠ 0, jump