A tie can occur in the following ways.
First, we could get a board where nobody has 3-in-a-row. In that case, up to symmetry, the board must look one of the three tied positions you can achieve in tic-tac-toe:
X X O X X O X X O
O X X O O X O O X
X O O X X O X O X
There are $32$ boards in this category. For the first board, we can rotate it in $4$ ways, reflect it or not, and swap X
with O
or not, giving $16$ variations; for the second and third, reflections don't help (since they're symmetric) so we get $8$ variations of each.
Second, we could get a board where both players have one 3-in-a-row. No player can claim a diagonal: if that happens, there is no other 3-in-a-row for the other player to claim. Similarly, no player can claim both a vertical and a horizontal 3-in-a-row. So we are left with boards like this one:
X X X
O O O
X O O
There are $72$ boards in this category. We can choose in $2$ ways whether the 3-in-a-rows are vertical or horizontal. Once we do, we can permute the "win for X
" line, the "win for O
" line, and the third line in $3! = 6$ ways, and specify the outcomes along the third line in $2^3 - 2 = 6$ ways (it cannot be X X X
or O O O
, but any of the other outcomes are valid).
So the probability of a tie is $\frac{32 + 72}{2^9} = \frac{104}{512} = \frac{13}{64}$, leaving a probability of $\frac{51}{128}$ that X
wins and a probability of $\frac{51}{128}$ that O
wins. (Each of these is just over $39.8\%$.)