Skip to the game
Tic Tac Toe

Tic Tac Toe

Play Tic Tac Toe online for free against the computer or a friend. No download or sign-up.

Play Tic Tac Toe

XYou
0
Draws
0
OComputer
0

Loading the game…

3×3 board · get 3 in a row to win

Keyboard: arrow keys move between squares, Enter places a mark, or press 1–9 to play a square directly.

Game settings
Changing a setting starts a new round.
Board
Opponent
Difficulty
You play as

How it works

How to play Tic Tac Toe

A round of classic Tic Tac Toe takes about a minute: pick your board and opponent, trade turns as X and O, and complete a line before the other side does.

  1. Step 01

    Pick a board and opponent

    Choose 3×3, 4×4, 6×6, or 9×9 under Game settings, then play the computer on Easy, Medium, or Hard, or switch to 2 players.
  2. Step 02

    Take turns

    X always moves first. Tap or click an empty square to place your mark, then wait for the reply.
  3. Step 03

    Complete a line

    Get 3 in a row on 3×3, 4 on 4×4, or 5 on 6×6 and 9×9: across, down, or diagonally. If nobody can complete a line, it's a draw.

Features

Four boards, three computer levels, and a friend mode

  • Classic 3×3 and bigger boards

    Play classic 3×3 Tic Tac Toe, or 4×4, 6×6, and 9×9 boards where you need 4 or 5 in a row to win.

  • Three computer levels

    Easy plays at random, Medium blocks your threats, and Hard plays perfectly on 3×3 and searches ahead on bigger boards.

  • Two player mode

    Tic Tac Toe for two players on one phone, tablet, or computer: pass it back and forth. X always moves first.

  • Scores and undo

    Wins, losses, and draws are kept for each board and opponent and saved in your browser. Undo takes back a move.

  • Keyboard and screen reader friendly

    Move with the arrow keys, press Enter to play, and hear every move announced.

  • Phones, tablets, and computers

    Runs in any modern browser on a PC, phone, or tablet, with a board that resizes to fit, in light or dark mode.

About the game

Tic Tac Toe: the rules, the computer, and how to win

Everything about the game: the rules, the computer opponent, playing with friends, strategy, and the names it goes by around the world.

Tic Tac Toe is the classic game of X's and O's. Two players take turns marking a 3×3 grid, and the first to get three in a row wins. Here you can play Tic Tac Toe online against a computer with three levels or a friend beside you, on the classic board or one of three bigger ones.

The rules of classic 3×3 Tic Tac Toe

The rules fit in a sentence: X moves first, the players take turns placing one mark in an empty square, and the first to line up three marks across, down, or diagonally wins. There are eight ways to win on a 3×3 board, three rows, three columns, and two diagonals. If all nine squares fill up and nobody has a line, the game is a draw, which American players often call a cat's game. No game can last longer than nine moves, so a round takes about a minute.

To play here, tap or click an empty square. On a keyboard, move between squares with the arrow keys and press Enter or Space to place your mark, or press the number keys 1 to 9 to play a square directly, reading the board left to right like a phone keypad. New round clears the board, and Undo takes back a move if your finger slips.

Play Tic Tac Toe against the computer

Single-player Tic Tac Toe pits you against a computer opponent with three levels, so the game suits a first-timer and a seasoned player alike:

  • Easy picks a random empty square. It's the friendliest level, and new players can win often.
  • Medium always takes a winning square and always blocks a line you're about to complete. The rest of the time it plays its best move only about half the time, so you can beat it by setting up two threats at once.
  • Hard, on the 3×3 board, checks every possible way the game could go before each move. This Tic Tac Toe AI never makes a mistake there, so it's unbeatable: the best you can do is a draw. On bigger boards it looks several moves ahead instead.

Under You play as, pick X to take the first move, or O to hand the opening to the computer. For a real Tic Tac Toe challenge, play Hard as O and try to draw ten rounds in a row. If you manage it, you know every defensive rule in the game.

Playing a friend on the same screen

Choose 2 players to play Tic Tac Toe with friends or family on one phone, tablet, or computer. You take turns on the same screen, and the scoreboard switches to Player X and Player O so you can keep a running score over a whole evening. 2 player Tic Tac Toe has its own page that opens straight into this mode, with tips for each board size.

This is local multiplayer: both players share one device. There's no online matchmaking, chat, or friend list, so you simply pass the phone or slide the laptop across. Because X moves first and has the edge, it's fairest to swap who plays X after every round.

Tic Tac Toe strategy: how to win, or never lose

Tic Tac Toe looks like luck, but it's a solved game: if both players make no mistakes, every game ends in a draw. Winning therefore comes down to spotting your opponent's errors. Three ideas cover nearly all of it.

First, squares aren't equal. The center sits on four of the eight lines, each corner on three, and each edge on only two, so the center and corners give you the most chances. Second, on every turn, win if you can, and block if your opponent is about to win. Third, look for a fork: a move that makes two lines that each need one more mark. Your opponent can block only one, so you win on the next move.

As X, opening in a corner sets the most traps, because O's only safe reply is the center. As O, answer a corner with the center and the center with a corner. The most common beginner loss comes when X opens in a corner and O replies on an edge next to it, and from there X can always force a win.

X does have an edge. Of all 255,168 possible games on a 3×3 board, X wins 131,184, O wins 77,904, and 46,080 end in a draw. For the full move-by-move checklist, read how to win at Tic Tac Toe, or start with the rules for every board.

Tic Tac Toe for kids

Tic Tac Toe is often the first strategy game children learn. It asks them to take turns, think one move ahead, and spot a line forming, and every round ends quickly, so a loss never stings for long. Start a young player on Easy, where they'll win plenty of games, then move up to Medium when they start blocking without being told.

Playing a child yourself works well too. Choose 2 players, say each move out loud, and let them use Undo to try a different square after a mistake. Once every 3×3 game ends in a draw, 4x4 Tic Tac Toe gives them something new to work out.

Play on PC, phone, or tablet, with no download

The game is a web page, so it works in any modern browser on a Windows or Mac PC, a Chromebook, an iPhone or iPad, or an Android phone or tablet. The board grows or shrinks to fit the screen, so it's just as easy to play on a desktop monitor as on a phone on the bus, in light or dark mode.

Some school and work networks filter games. This one is an ordinary web page with no plug-in to install, so wherever regular sites are allowed, Tic Tac Toe is unblocked too, though each network sets its own rules. It isn't an offline app, so you need a connection to open the page. After that, the computer's moves are worked out in your browser, and your moves aren't sent to a server.

Noughts and crosses, X and O, and other names

The game goes by many names. In Britain and much of the Commonwealth it's noughts and crosses, after the O (a nought, or zero) and the X (a cross). Elsewhere you'll hear the X and O game, Xs and Os, or tic-tac-toe with hyphens, and they're all the same game. The British name is the older one in print: noughts and crosses appears in 1858, while the American name tic-tac-toe took over during the 20th century.

Tic Tac Toe also has a place in computer history. OXO, a version written in 1952 for the EDSAC computer at the University of Cambridge, is often counted among the first video games ever made.

Bigger boards when 3×3 gets easy

Once every game of classic Tic Tac Toe ends in a draw, a bigger board brings the surprise back. 4x4 Tic Tac Toe needs four in a row, so every line runs from edge to edge. 6x6 and 9x9 Tic Tac Toe need five in a row, which turns the game into a battle of open lines and double threats. For a different kind of challenge, Ultimate Tic Tac Toe plays nine small boards inside one big one, and Gomoku is five in a row on a 15×15 board.

Where your scores are kept

Your wins, losses, and draws are kept for each board size and opponent in your browser's local storage on this device, along with your board, opponent, level, and mark. That's 16 scoreboards in all, four opponents on each of four boards, so a run of draws against Hard on 3×3 never mixes with quick wins on Easy. Your score is waiting when you come back, and Reset scores clears only the scoreboard you're looking at. The game doesn't send your moves or scores to a server, and the privacy policy lists exactly what is stored.

FAQ

Tic Tac Toe questions

Quick answers about playing Tic Tac Toe online: the rules, the computer, two players, and more.

Can you beat the computer on Hard?

Not on 3×3: Hard checks every possible continuation, so the best you can do is a draw. On the bigger boards there are far too many positions to check, so Hard looks several moves ahead in about a third of a second. It is tough but not perfect. Medium can be beaten on any board with a fork.

Who goes first in Tic Tac Toe?

X always moves first. Against the computer, choose X to start yourself or O to let the computer open. In two-player mode, whoever is X starts.

What are the bigger boards?

4×4 needs 4 in a row. 6×6 and 9×9 need 5 in a row, like Gomoku. The longer line keeps the bigger boards fair: with only 4 in a row on 6×6, the first player can always force a win.

Is Tic Tac Toe always a draw?

On 3×3, 4×4, and 6×6, yes: with perfect play from both sides these are proven draws. 9×9 with five in a row has no published solution. Either way, winning means spotting your opponent's mistakes, and the how to win guide shows how.

Can I play Tic Tac Toe with friends?

Yes. Choose 2 players under Game settings, or open 2 player Tic Tac Toe, and take turns on the same phone, tablet, or computer. The scoreboard switches to Player X and Player O. It's multiplayer on one device: there's no online matchmaking with other people.

Are my scores saved?

Yes. Scores and settings are stored in your browser's local storage on this device, with a separate scoreboard for each board size and opponent, and none of it is uploaded. Reset scores clears the scoreboard you're looking at.

Can I play with a keyboard or screen reader?

Yes. Tab to the board, move with the arrow keys, and press Enter or Space to place a mark. On 3×3 you can also press 1 to 9 to play a square directly. Every move and result is announced.

Is this Tic Tac Toe game free?

Yes. Every board, difficulty, and mode is free, with no account to create. It's a browser game, so there's nothing to download on a PC, Mac, Chromebook, phone, or tablet.

Is Tic Tac Toe good for kids?

It's a common first strategy game: the rules fit in a sentence and a round takes about a minute. Start a child on Easy, then Medium, or play them yourself in 2 players mode.