Drop a disc, block a threat, build two at once. A game you can learn in ten seconds and still lose in ten moves.
How this version works
The board is seven columns by six rows. You take turns with the computer dropping gold or coral discs into a column, and the first to line up four in a row, across, down or diagonally, wins. Discs fall with a short animation, the winning four light up, and a preview shows where your disc will land before you commit. A full board is a draw.
Tap or click a column to drop. On a keyboard, use the arrow keys and Enter. There are Easy and Hard settings, and the board fits any screen.
The game has been solved
Four in a row is a solved game. In 1988 James Dow Allen and Victor Allis, working independently, showed that the player who moves first wins with perfect play, as long as they start in the middle column. That doesn't make it easy: perfect play means avoiding every mistake across up to 42 moves, and the computer here isn't perfect either.
How to beat the computer
- Start in the middle column. It's part of more possible fours than any other.
- Build two threats at once. A single three-in-a-row gets blocked. Two different winning squares can't both be.
- Watch the squares above your threats. If your winning square sits directly above one your opponent can fill, you give them a free block.
- Think odd and even rows. The first player tends to want threats on odd rows counting from the bottom, the second player on even rows.
- Block diagonals early. They're the line people forget to watch.
The trap that wins games
Build three in a row along the bottom row with both ends open. The opponent can block only one end, and you win through the other. The same shape higher up the board works whenever the squares beneath both ends are already filled. When you play second, look for this on every turn, and when you play first, aim to create it.
Defensive habits
- Before dropping a disc, check which square above it you're handing the opponent.
- Scan diagonals after every move. They hide the quiet threats.
- Never leave a three-in-a-row with two empty ends, even if you can fill one end now.
Why it is a good thinking game
The commercial version sold from the 1970s made the game a household name, and it's easy to see why it spread: the rules fit in a sentence, but winning means looking several moves ahead. Every turn forces you to ask the same two questions: what is my opponent threatening, and what am I threatening? Players who learn to answer both quickly improve fast, and that habit carries over to chess, checkers and plenty of real-life planning.
From prompt to playable
Like every original here, this began as a plain-English brief to an AI coding tool. Read the prompt on the game page.
Questions people ask
How do I win?
Get four of your discs in a row, horizontally, vertically or diagonally, before the computer does.
Who goes first?
You do. Starting in the centre column is the strongest opening.
Can I play on a phone?
Yes. Tap a column to drop a disc.
Keep reading
- Play Reversi Online Free Against the Computer
A game where the lead changes hands all the time, and the player ahead in discs is often the one in trouble.
- Play Dots and Boxes Online Free vs the Computer
Draw a line, close a box, take another turn. The trick is knowing when not to.
- Play Checkers Online Free Against the Computer
English draughts on an eight-by-eight board, with the compulsory captures that turn a simple game into a tactical one.