Gomoku (Five in a Row) – Play the Computer on a 15×15 Board
Place stones in turn and be the first to line up five in a row, horizontally, vertically or diagonally. The board is 15×15 and there are no restricted moves. Choose from four computer levels and decide whether to play first (black) or second (white). Want another board game? Try Connect Four or Reversi.
🔒 Runs in your browser · Your data is never sent to a server
- Black
- 0
- White
- 0
How to use
- Choose the computer level (Easy, Normal, Hard or Expert) and your side (first as black, or second as white). A new game starts when you choose.
- Click (or tap) an intersection to place a stone. Black moves first and the players alternate.
- Line up five of your stones (six or more also counts) horizontally, vertically or diagonally to win. The winning line is highlighted.
- Use "Undo" to take back your last move, or "New game" to start over.
Notes
- Everything runs in your browser and nothing is sent to a server. The computer’s moves are also calculated in your browser.
- The board is 15×15 and neither side has restricted moves. Five or more in a row (including an overline of six or more) wins.
- The computer is a simple engine that scores line shapes and looks a few moves ahead (up to 4 on Expert). It is not as strong as dedicated software, and strong players can beat it.
- Easy plays mostly at random near the existing stones (it always takes a winning move when it has one). Normal, Hard and Expert look further ahead and take a little longer to move.
- When several moves score equally, the computer picks one at random, so the same position will not always play out the same way.
- Undo takes back your last move together with the computer’s reply. Game progress is not saved; reloading the page starts a new game.
- With a keyboard, move between intersections with the arrow keys and place a stone with Enter or Space.
Glossary
Gomoku
A two-player game in which players take turns placing black and white stones on a grid; the first to get five of their own stones in an unbroken row horizontally, vertically or diagonally wins. This page uses no restricted moves, to keep the rules simple.
Restricted moves
Competition rules that forbid certain shapes for the first player (such as double-three, double-four and overlines) to offset the first-move advantage. This page does not use them, so any move is allowed.
Overline
A row of six or more of your own stones. Here it is not a foul: five or more in a row wins.
FAQ
Does a row of six or more stones win?
Yes. This page has no restricted moves, so any row of five or more stones, horizontally, vertically or diagonally, wins. Competition rules that ban double-three, double-four and overlines for one side are not applied.
Does moving first give an advantage?
In Gomoku without restricted moves, the first player has a clear advantage. Beginners may want to start as black, then try playing second or beating the Expert level.
What is the difference between the computer levels?
Easy plays mostly at random near existing stones. Normal picks the move with the best immediate value (extending its own lines and blocking yours), Hard looks 2 moves ahead and Expert looks 4. At every level the computer takes a winning move when it has one.
Can the game end in a draw?
Yes, if all 225 points are filled and nobody has made five in a row. In practice it almost never happens.
Is my game saved?
No. A game lasts only while the page is open; reloading starts a new one. The tool runs entirely in your browser and sends no data to a server.
Share this page
