About
An elegant, framework-free game of Tic-Tac-Toe — known in some corners of the world as noughts and crosses. Play against a friend on the same device, or take on the computer.
"Shall we play a game?" — WOPR, WarGames (1983)
How to play
Two players take turns marking squares on a 3×3 grid — one plays X (crosses), the other O (noughts). The first to line up three of their marks in a row — horizontally, vertically, or diagonally — wins. If every square is filled with no winner, the game is a draw.
Game modes
- One player — you play X and move first against the computer.
- Two players — hand the device back and forth for local play.
The opponent
Choose how hard the machine plays:
- Playful — moves at random; a gentle warm-up.
- Wary — takes wins, blocks threats, but can be outfoxed.
- W.O.P.R. — perfect play by way of the minimax algorithm. As the film taught us: the only winning move is not to play. Against W.O.P.R. the very best you can hope for is a draw.
In one-player mode the computer takes a brief moment of "thinking time" before moving — because even a supercomputer likes to look thoughtful.
A nod to WarGames
This game tips its hat to the 1983 film WarGames, in which a military supercomputer called WOPR learns the futility of tic-tac-toe. Play a few rounds and the machine may get chatty — greetings, Professor Falken.
Under the hood
Pure static HTML, CSS, and JavaScript — no frameworks, no build step — hosted on Cloudflare Pages. Fully responsive, with light and dark themes that follow your system preference, and reduced-motion support.