Abstract. We derive midpoint criteria for solving Pell's equation x 2 − Dy 2 = ±1, using the nearest square continued fraction expansion of √ D. The period of the expansion is on average 70% that of the regular continued fraction. We derive similar criteria for the diophantine equation y 2 = ±1, where D ≡ 1 (mod 4). We also present some numerical results and conclude with a comparison of the computational performance of the regular, nearest square and nearest integer continued fraction algorithms.