Free game · No sign-up

Magic Square Puzzle — Make Every Line Equal

Make every line magically equal! Logic & addition

▶ Play nowSee all 16 games

  • 🎮 16 free games
  • 💾 Progress saves on this device
  • 📱 Works on phones & tablets

Play Magic Square

Make every line magically equal! Your stars, stickers and streak save on this device.

Magic Square Puzzle — Make Every Line Equal
Embed this calculator on your site

Free to use on class pages, blogs and course pages. Copy the code below and paste it into your page:

  • 🔥Keep a streakPlay a little each day to grow your day streak.
  • ⭐Aim for 3 starsBeat your best score and earn every star.
  • 🏅Collect stickersUnlock achievements in your sticker book.
  • 💪Mistakes are OKEvery round makes your brain a little stronger.

How it works

Everything you need to know about Magic Square

This free magic square puzzle asks you to place numbers in a grid so every row, every column and both diagonals add up to the same total, called the magic constant. Play the classic 3×3 square with the numbers 1–9 (every line totals 15), step up to the 4×4 square with 1–16 (every line totals 34), or take on the giant 5×5 (total 65) and 6×6 (total 111) boards. Live line sums turn green as each line becomes magic, so you always know how close you are. It runs in any browser, on phones and tablets too, with no sign-up.

How to play the magic square puzzle

  1. Pick a board. Choose 3×3 (numbers 1–9, magic constant 15), 4×4 (numbers 1–16, magic constant 34), 5×5 (numbers 1–25, magic constant 65) or 6×6 (numbers 1–36, magic constant 111). A few numbers start locked in place to get you going: two on the 3×3 board, six on the 4×4 board, 10 on the 5×5 board and 16 on the 6×6 board.
  2. Place a number. Tap or click an empty cell, then tap a number in the palette below the grid. Each number can be used once. On a computer you can also move with the arrow keys and type numbers; two-digit numbers work on the 4×4 and bigger boards.
  3. Change your mind. Tap a filled cell to clear it, or press Clear to empty every cell you placed.
  4. Watch the line sums. The totals beside each row, under each column and at the ends of the diagonals update as you play. A sum turns green when it hits the magic constant and red when it goes over or a full line misses.
  5. Press Check. If cells are still empty, Ollie tells you how many are left and how many lines are already magic. When the grid is full, Check either celebrates the solve or points to the lines that do not total the constant yet.

Any correct arrangement counts, so if you find a different magic square from the one the puzzle started from, it is still a win. Press New Puzzle for a fresh square; each one is built by rotating, flipping or transforming a known magic square, so the givens change every time.

What is a magic square?

A magic square is a square grid of numbers in which every row, every column and both main diagonals have the same sum. That shared sum is the magic constant. A square that uses each whole number from 1 to n² exactly once is called a normal magic square, and its constant is n(n² + 1) ÷ 2:

Board (order) Numbers used Magic constant
3×3 (order 3) 1–9 3 × 10 ÷ 2 = 15
4×4 (order 4) 1–16 4 × 17 ÷ 2 = 34
5×5 (order 5) 1–25 5 × 26 ÷ 2 = 65

A quick way to see why the 3×3 constant is 15: the numbers 1 to 9 add up to 45, and the three rows share that total equally, so each row must be 45 ÷ 3 = 15. The same idea gives 136 ÷ 4 = 34 for the 4×4 board. Magic squares are thousands of years old. The 3×3 Lo Shu square comes from ancient Chinese legend, and Albrecht Dürer carved a famous 4×4 square into his 1514 engraving Melencolia I.

How to solve a 3×3 magic square

The 3×3 square looks like guesswork, but a few facts make it a short logic puzzle:

  • 5 goes in the center. The middle row, middle column and both diagonals all pass through the center cell. Working through those four lines shows the center must be the middle number, 5.
  • Opposite cells add to 10. Each line through the center totals 15, and 15 − 5 = 10, so the pairs 1 + 9, 2 + 8, 3 + 7 and 4 + 6 sit opposite each other.
  • Even numbers go in the corners, odd numbers on the edges. Each corner sits on three lines, and only 2, 4, 6 and 8 fit all three. That leaves 1, 3, 7 and 9 for the edge middles.
  • Use the givens. Once one corner is placed, its opposite corner is fixed (they add to 10), and the remaining cells follow from the row and column sums.

One finished example is the Lo Shu square: 4 9 2 / 3 5 7 / 8 1 6. Every normal 3×3 magic square is this square rotated or reflected, so there are eight versions in all. Try to spot which one each new puzzle is.

How to solve a 4×4 magic square

The 4×4 board has far more possible answers (880 different normal 4×4 magic squares, not counting rotations and reflections), so treat it like a logic puzzle and let the line sums guide you:

  • Start with the fullest line. The puzzle locks six numbers in place. Find a row, column or diagonal with three numbers already in it; the last cell is simply 34 minus their sum.
  • Think in pairs that make 17. In many 4×4 squares, including Dürer’s, cells that mirror each other through the center add to 17 (1 + 16, 2 + 15, and so on). It is a strong first guess; the green and red sums will confirm it or rule it out.
  • Use the 2×2 corners and center. In Dürer’s square (16 3 2 13 / 5 10 11 8 / 9 6 7 12 / 4 15 14 1) the four corners, the four center cells and each 2×2 quadrant also total 34. Not every 4×4 square has these extras, but checking them is a quick test.
  • Do not chase one line. A number can make one row magic and break a column. Glance at every line that crosses the cell before you commit.

Hints, stars and scoring

  • Hint places one correct number. If you have a wrong number on the board, the hint fixes that cell first. Hinted cells show a 💡 so you can see where the help went.
  • Stars: solve with no hints for 3 stars. One hint on 3×3 (or up to two on 4×4) still earns 2 stars, and any solve earns at least 1 star.
  • Records: the stats bar shows your solves, fastest time, fewest hints and hints used this puzzle. Fastest time is kept separately for each board size, so you can race your own best.
  • Stickers and XP: ten stickers to collect, such as solving a 3×3 in under 60 seconds, a 4×4 with no hints, or the giant 5×5 and 6×6 boards. Every solve adds XP to your Effortless Math player level and daily goal, shared across all our free games.

Progress is saved in your browser on this device, so there is no account to create.

Skills and grade levels

The 3×3 square is a good fit from about grade 2, once students can add three single-digit numbers. It builds fluency with sums within 20 (Common Core 1.OA.C.6 and 2.OA.B.2) and gives a reason to break numbers into pairs that make 10. The 4×4 square suits grades 4–8: students add four numbers up to 16, keep a running total toward 34, and reason about several constraints at once. Both boards practice the Mathematical Practices of persevering in problem solving (MP1) and looking for structure (MP7).

To strengthen the underlying skills, see our guide to addition, practice spotting rules with number patterns and sequences, and read how grid puzzles build logical thinking.

Tips for parents and teachers

  • Warm-up (5 minutes): project a 3×3 puzzle and ask the class to argue where 5 must go before anyone places a number.
  • Talk about the why: ask students to explain the “45 ÷ 3 = 15” reasoning. Explaining it is more valuable than solving quickly.
  • No-hint challenge: once students solve 3×3 with hints, challenge them to earn 3 stars. Then move to 4×4.
  • Exit ticket: have students write one rule they discovered, such as “opposite cells add to 10”.
  • Extension: ask what the constant would be for a 5×5 square (65) and why.

Looking for more puzzles like this? Try Math Doku, where cages must hit a target with +, −, × or ÷, or Make the Number, a 24-style arithmetic puzzle. Browse every title on our free math games page.

Magic square FAQ

How do you solve a magic square puzzle?

Work out the magic constant first (15 for 3×3, 34 for 4×4). Then fill the most complete line, using the constant to find the missing number, and keep checking every row, column and diagonal that crosses each cell you fill. On a 3×3 square, put 5 in the center and the even numbers in the corners.

Is a 3×3 magic square always 15?

Yes, when it uses the numbers 1 to 9 once each. Those numbers total 45, and three equal rows means 45 ÷ 3 = 15. A 3×3 square built from other numbers can have a different constant.

What are the rules of a magic square?

Use each number once, and make every row, every column and both main diagonals add up to the same total.

How do you solve a 4×4 magic square?

Every line must total 34. Start with lines that already have three numbers, try pairs that add to 17 in mirrored cells, and use the live sums to test each placement.

Is there more than one correct answer?

Yes. There are eight 3×3 versions (rotations and reflections of one square) and hundreds of 4×4 squares. This game accepts any arrangement that makes every line magic.

Is the magic square game free, and does it work on a phone?

Yes. It is free, needs no account, and works with touch on phones and tablets as well as with a mouse or keyboard.

Are there bigger magic squares?

Yes. Besides 3×3 (numbers 1–9, every line totals 15) and 4×4 (1–16, total 34), you can choose 5×5 (1–25, total 65) and 6×6 (1–36, total 111). The magic total is always n(n²+1)/2. Bigger boards start with more numbers already placed, and any correct arrangement is accepted.

Can I print magic square puzzles?

Yes. Press 🖨️ Print puzzle to print two copies of the current puzzle plus an answer key — handy for homework, centers or early finishers.

Can I print a certificate?

Yes. When you finish a round with at least one star, type a name in the box on the results screen and press 🖨️ Print certificate. The certificate shows the game, the stars earned, the main scores and the date — a nice way to celebrate progress at home or in class.

Related to This Article

What people say about "Magic Square Puzzle Online — Free 3×3 to 6×6 Game"?

No one replied yet.

Leave a Reply