Magic Square
Arrange the numbers so every row, column, and diagonal adds up to the magic constant.
The rules
How to play
- 01
The grid
A magic square is an n×n grid. Fill it so every number from 1 to n² appears exactly once — 1–9 for a 3×3, 1–16 for a 4×4, 1–25 for a 5×5.
- 02
Rows
Every row must add up to the magic constant. No row can fall short or overshoot the target sum.
- 03
Columns
The same rule applies vertically: every column must also sum to the magic constant.
- 04
Diagonals
Both main diagonals — corner to corner — must equal the magic constant too. Rows, columns, and diagonals together define the solution.
- 05
The magic constant
The target follows M = n(n² + 1) / 2 — that is 15 for a 3×3, 34 for a 4×4, and 65 for a 5×5 grid.
- 06
Prefilled cells
Shaded cells arrive with fixed numbers you cannot change. They anchor the puzzle and guarantee a single valid solution.
Play smarter
Habits of fast solvers
Use the sums
If a row or column has only one empty cell, the missing number is the magic constant minus the numbers already there.
Check diagonals first
Diagonals have the fewest cells, so they are often the most constrained. Start by looking at what they can hold.
Complementary pairs
Numbers that sum to n² + 1 — like 1+16, 2+15, 8+9 in a 4×4 — pair up. Opposite cells often contain these pairs.
Process of elimination
Track which numbers are already placed. When sum constraints leave only one candidate for a cell, that is your answer.
Trial and error
Sometimes you have to try a number and follow the consequences. If it leads nowhere, undo and try the next one.
Watch & learn
Two minutes to mastery
From the Intel desk
Reading for the curious
Magic Square Puzzle: A Complete Beginner's Guide to Sum Symmetry
Learn how to solve Magic Square puzzles from scratch. Discover the ancient history, understand the magic constant, follow our visual step-by-step tutorial, and master the art of creating perfect numerical harmony where every row, column, and diagonal sums to 34.
Magic Square Strategies: Mastering the Art of Perfect Sums
Level up your Magic Square solving with advanced strategies including frequency analysis, exhaustive possibility mapping, and systematic constraint propagation. Learn to recognize patterns and solve 4x4 puzzles with speed and confidence.
Keep going
Where to next
Fresh every day
The Daily Magic Square
One shared puzzle for everyone, every day. Build a streak and compare your time.
Go deeper
Rules & strategy guide
From the magic constant to complementary pairs — the complete written guide with examples.
Beyond the grid
Explore all puzzles
Sudoku, Nonograms, Kakuro and fifteen more logic games await.