Checking if a coin is fair: z-test or t-test I have seen many questions on this topic, but none of them could answer my question. Suppose I flip a coin 1,000 times and got 490 heads. I want to test if the coin is fair. I don't want to use the binomial distribution but instead I'd like to use the normal approximation. I want to test $H_0: p = 0.5$ vs $H_1 : p \neq 0.5$.
If I use the t-test, I would have to estimate the sample variance, and the reason for using a t-test would be that I don't know the population variance.
However, is it actually true that I don't know the population variance? I'm supposed to compute a test statistic, assuming that null is true. If I assume the null is true, I do know the population variance, because I know $p$ (because I assume $p = 0.5$). I should then use the z test.
Which test should I use, and why?

Use the z test.
In the case where you assume the binomial parameter is $p=p_0$, then the variance would be determined since it is a function of the binomial parameter.  If I recall correctly, the resulting test statistic would be a score statistic.
In the case where you use the estimated binomial parameter in the variance (resulting in a Wald statistic if I remember correctly, though I might have permuted those) you would still use a z test because the variance is determined by the estimate of the binomial parameter.
