Canonical: https://toolipedia.app/n-queens-solver

# N-Queens and Knight's Tour Solver

Enter a board size and see one or all solutions of the N-Queens puzzle drawn on the board, or find a knight's tour from any start square with numbered moves.

Breadcrumbs: Toolipedia > Everyday tools > Games, puzzles and random picks > N-Queens and Knight's Tour Solver

## About N-Queens and Knight's Tour Solver

Two classic chess puzzles. N-Queens asks you to place N queens on an N by N board so that none attacks another. Choose one solution or all of them: the page counts them (92 for 8 by 8), reports how many are different up to rotation and reflection (12), and lets you browse each one on the board. Knight's tour asks for a path of knight moves that visits every square exactly once, from a start square you choose; the page draws the path with numbered moves and says if it is closed. Boards with no tour, such as 4 by 4, are reported as such.

## How to use N-Queens and Knight's Tour Solver
1. Choose N-Queens or Knight's tour and enter the board size.
2. For queens pick one solution or all solutions and a solution number; for the knight type a start square like a1.
3. Read the board drawing, the list of squares and the counts, or the numbered tour and whether it is closed.

## Why use this tool?
- Private: everything happens in your browser. Nothing you enter is uploaded.
- Free, with no sign-up, no watermark and no limit on how often you use it.
- Works on phones, tablets and computers: Android, iPhone, Windows, Mac and Linux. Nothing to install.
- Free to embed on your own website, with a ready-made code to copy.

## Also known as
- n queens and knight s tour solver
- n queens solver
- eight queens solutions
- knights tour solver
- chess puzzle solver
- how many solutions n queens

## Frequently asked questions

### How many N-Queens solutions are there for each size?

For N = 4 to 8 there are 2, 10, 4, 40 and 92. For 9 to 12 there are 352, 724, 2,680 and 14,200. There are none for N = 2 and N = 3, and one for N = 1.

### Does every board have a knight's tour?

No. There is none on 2×2, 3×3 or 4×4 boards, and on 5×5 a tour only exists from squares of the same colour as the corner. From 6×6 upward tours exist; the page searches from the square you choose and says so if none is found.

### What is a closed knight's tour?

A tour whose last square is one knight move from the first, so the path forms a loop. The page tells you whether the tour it found is closed; it does not search specially for closed tours.

### Is N-Queens and Knight's Tour Solver free?

Yes. N-Queens and Knight's Tour Solver on Toolipedia is free to use, with no sign-up and no watermark.

### Is it safe to use?

Yes. Everything is worked out in your browser, and nothing you enter is sent to our server.

### Does it work on my phone?

Yes. It works in any modern browser on Android and iPhone, as well as on tablets and computers. There's nothing to install.

### Do I need an account?

No. Just open the page and use the tool. There's no sign-up and no email needed.

### Can I put N-Queens and Knight's Tour Solver on my own website?

Yes. Use the Embed on your site button under the tool to copy a short piece of code and paste it into your page. It is free, needs no account, and the tool keeps working inside your page.

## Related tools

More free tools that go well with N-Queens and Knight's Tour Solver:
- [Box-Pushing Puzzle Solver](https://toolipedia.app/box-pushing-puzzle-solver)
- [Logic Brain Teasers and Peg Solitaire](https://toolipedia.app/logic-brain-teasers-and-peg-solitaire)
- [Chess Board Editor and Notation Tool](https://toolipedia.app/chess-board-editor-and-notation-tool)
- [Sudoku solver](https://toolipedia.app/sudoku-solver)
- [Rubik's Cube solver](https://toolipedia.app/rubiks-cube-solver)
