Maze Generator

A printable maze with a verified path from start to finish.

Maze settings
No maze yet

ROT.js license
Guide

Maze Generator: Printable Puzzles & Matching Solutions

Build a rectangular maze from 5 to 30 columns and rows, with a start on the top edge and an exit on the bottom edge. This tool uses Eller's maze algorithm and checks that every passage connects, the passage graph has no loops and the solution follows valid steps. The same generated grid supplies the preview, text export and printable answer key. No AI call is needed to generate a maze.

For

Teachers, families and puzzle makers preparing printable maze activities.

Problem

A puzzle needs a usable entrance and exit and an answer key that matches the exact generated layout.

Output

One connected rectangular maze with a verified solution, repeatable settings and separate printable puzzle and answer pages.

Use when

A classroom puzzleCreate a small rectangular maze, add a sheet title and print the puzzle without the answer key for learners. Keep a separate key for checking their route.
A repeatable handoutKeep the columns, rows and seed shown on the sheet. With the same algorithm version, those settings recreate the same layout without uploading or saving a puzzle.
A narrow or wide mazeChoose rows and columns independently to change the rectangle. The maze keeps square passage tiles in its preview and print layout rather than stretching them.

What to include

Choose whole-number dimensionsUse 5-30 columns and 5-30 rows. These count logical maze cells, not wall tiles. A 12-column maze is represented by 25 tiles across including walls and passages.
Choose a repeatable seedUse an integer from 1 to 4294967295, or select New seed and generate again. A different seed can produce a different maze, but unique output is not promised.
Set the printed presentationThe sheet title accepts up to 60 characters. Select A4 or US Letter and decide whether exports include the separate answer key. These choices do not change the maze.

Steps

01Generate and verifyEnter the dimensions and seed, then select Generate maze. The browser creates the maze, finds its route with four-direction A* and independently checks connectivity, absence of loops and the answer path before displaying it.
02Inspect the answerSwitch Preview to Answer key to see the route from S to E. The route moves up, down, left or right through open passages; it never crosses a wall or takes a diagonal shortcut.
03Export the same puzzleCopy and text download use # for walls, S and E for the endpoints and dots for the optional solution. Print / Save as PDF opens browser printing with one puzzle page and an optional separate answer page.

Try this

Starter maze
12 columns, 12 rows, seed 42

A square maze with repeatable settings and a separate answer key.

Tall rectangle
5 columns, 20 rows, seed 123

A narrow maze that retains square passages in the printable layout.

Puzzle-only handout
10 columns, 10 rows, A4, Include answer key off

A single printed puzzle page without the solution path.

Good output

  • Every logical cell and open passage belongs to one connected maze.
  • The passage graph has no cycles, giving one simple route between the endpoints.
  • The answer starts at S, ends at E and follows adjacent open tiles.
  • Preview, text and print use the same verified grid.
  • Changing dimensions or seed invalidates old exports until another maze is generated.

Avoid

Equating size with difficultyMore cells do not guarantee a harder puzzle. Route length, branches and the solver's experience all matter. This tool does not assign difficulty ratings.
Changing a seed without regeneratingChanging generation settings clears the old result. Select Generate maze again before copying or printing, so the exported settings match the puzzle.
Printing the wrong paper sizeMatch the selected paper to the printer dialog, disable browser headers and footers if necessary, and review the page preview before distributing a handout.

Limits

Rectangular mazes only, 5-30 logical cells on each side, fixed top entrance and bottom exit. No custom shapes, uploaded artwork, difficulty scores or alternate algorithms.
Seeded output uses Eller / ROT.js 2.2.1. Repeatability is tied to that version and the dimensions, not a promise that every seed produces a unique maze.
Generation and result verification run locally. The tool adds no generation request, saved history, tracking or input-bearing share link. Existing page delivery and aggregate analytics still apply.
A4 and US Letter printing depends on the browser. Print / Save as PDF is a browser command, not a separately generated PDF download. Text exports are best viewed in a monospaced font.
A maze is a visual puzzle. Text export describes walls and passages but is not an equivalent nonvisual gameplay experience.

FAQ

Does every maze have a solution?

Each displayed result passes a connectivity and no-cycle check. Its answer path is independently checked against the grid and must connect the two openings using only adjacent open tiles. A failed result is not exported.

Can I recreate a previous maze?

Yes, use the same columns, rows and seed with Eller / ROT.js 2.2.1. The settings are included in text and printed exports. Reloading the page clears the current result and restores defaults.

How do I print without the answers?

Turn off Include answer key in exports, then select Print / Save as PDF. The on-screen Answer key preview remains available, but the export contains only the puzzle.

Does a larger maze mean a harder maze?

Not necessarily. Grid size and solving difficulty are different. This tool supplies dimensions and a verified route, not a difficulty score or age suitability rating.

Can I download the maze?

Download text saves the grid and optional dotted answer path as maze.txt. To save the visual maze as a PDF, use Print / Save as PDF and choose the browser's PDF destination.

Is AI required?

No. Generation, verification and export run in the browser without a model request. JavaScript is required for the interactive tool.