Apps Part of Printshop

Maze Maker (Rectangle, Hexagon, Round and Shapes)

Printable mazes in squares, hexagons or circles, cut to a heart, star or your own shape.

More options

One text line per row; # marks a cell inside the maze. Columns and rows then come from the drawing.

The same seed and settings always give the same puzzles. Change it for new ones.

Try an example: · ·

More about this tool

How it works

Make printable mazes with square or hexagon cells or round “theta” mazes, optionally cut to a heart, star, circle, diamond, triangle or a shape you draw with # signs. Choose the recursive backtracker (long corridors), Kruskal or Wilson (uniform random) algorithm, up to six mazes per page and answer keys with the solution path.

  • Every shape is a graph of cells whose sides are either shared with a neighbour or part of the outer wall. Square and hexagon grids can be cut to an outline (tested at each cell centre); only the largest connected group of cells is kept. Round mazes have one centre cell and rings whose cell count doubles when cells get wider than two ring heights.
  • The maze is a spanning tree of that graph, so exactly one path joins the entrance (top) and the exit (bottom, or the centre of a round maze). Recursive backtracker = randomised depth-first search (about 10 % dead ends); Kruskal = random walls removed with union–find (about 30 %); Wilson = loop-erased random walks, which pick every possible maze with the same probability.
  • The solution is found by breadth-first search through the open passages and drawn through the cell centres and the middle of each passage.

Very large mazes on small paper get thin walls; check the PNG preview before printing many copies.

Sources

Part of Printshop

Related tools

How to use the Maze Maker (Rectangle, Hexagon, Round and Shapes)

Print mazes with square or hexagon cells or round rings, cut to a heart, star or your own shape, with three algorithms and answer keys.

What it is for

The Maze Maker prints mazes for children, party bags, puzzle books or rainy afternoons. Choose square cells, hexagons or a round "theta" maze, cut square and hexagon grids to a heart, star, circle, diamond, triangle or a shape you draw with # signs, and put one to six mazes on a page. Answer-key pages draw the solution path in red.

Every maze is a spanning tree of its cells: each cell can be reached, there are no loops and exactly one path joins the entrance and the exit. The entrance is at the top; the exit is at the bottom, or in the centre of a round maze. On the page a green dot marks the start and a red square the finish.

Worked example

The default 16 × 20 square maze with the recursive backtracker (seed maze-1) has 320 cells, 37 dead ends, and the solution passes 51 cells. The PDF has two pages: the maze and the answer.

Four heart-shaped mazes on a 24 × 22 grid (seed hearts) keep 332 cells inside the heart; their solutions pass 91 to 117 cells. A round maze with 14 rings made with Wilson's algorithm has 463 cells and 136 dead ends, with a 68-cell solution from the rim to the centre.

With hexagon cells, a star outline and Kruskal (26 × 22 grid, six per page, seed stars) each maze has 170 cells and 54 to 61 dead ends.

How to read the result

  • cells is the number of rooms in the maze after cutting the outline; only the largest connected part of a shape is kept.
  • deadEnds counts cells with a single opening — a rough feel for difficulty.
  • solutionCells is the length of the path from start to finish.
  • The table lists these numbers for every maze; the files are the PDF (mazes, then answers), the first page as SVG and a PNG preview.

Tips and common mistakes

  • The algorithm changes the character of the maze. The recursive backtracker makes long winding corridors with about 10 % dead ends. Kruskal and Wilson make many short side branches (about 30 %) — more choices, more backtracking. Wilson picks every possible maze with the same probability.
  • For young children use few rows and columns (8 × 10) and one maze per page.
  • In a round maze the rows field sets the number of rings (2–40); the cell count per ring doubles as the rings grow, so cells keep a similar size.
  • My own shape: write one line per row, # for a cell and . or a space for outside. The drawing sets the size, so the columns and rows fields are ignored.
  • Very large mazes on A4 get thin walls — check the PNG preview before printing many copies.

FAQ

Is there always exactly one way through?

Yes. The maze is a spanning tree, so the path between entrance and exit is unique.

Can I play the maze on screen?

In Printshop press Play on screen… and move the dot with the arrow keys or buttons; going back erases the trail.

Why does a star look jagged?

The outline is tested at each cell centre, so small grids follow the shape roughly. Use more columns and rows for a smoother edge.

How do I make a maze book?

Set up to 24 mazes with one or two per page and print the PDF; the answer pages come last, so you can keep them separate before stapling the sheets.

Guide last updated:

For scripts and AI agents

  • JSON API: POST https://printshopmaze.usefulweb.site/api/v1/calculate (same calculation as this page)
  • Interface description: OpenAPI 3.1 · AI guide: llms.txt
  • MCP server (Streamable HTTP): https://printshopmaze.usefulweb.site/mcp · tool name printshop_maze
Example request
curl -s -X POST https://printshopmaze.usefulweb.site/api/v1/calculate \
  -H 'content-type: application/json' \
  -d '{"shape":"rect","cols":16,"rows":20,"algorithm":"backtracker","seed":"maze-1"}'
Feedback · ideas & bug reports welcome