In a coil magnetometer, the size and uniformity of the bias magnetic field generated by the Helmholtz coil directly determine the accuracy of the solution of the geomagnetic direction. The design of traditional spherical coils relies heavily on the manual experience or mathematical derivation, making it difficult to obtain optimal parameters or requiring larger spherical coils. To address the problem, first, a coaxial symmetrical spherical coil model that improves space utilization was established. Second, an optimal design method for the spherical magnetic field generation coil based on a differential evolution algorithm was proposed. Third, the optimal bias magnetic field was obtained without increasing the volume of the coil. The verification results showed that the magnetic non-uniformity and magnetic gradient of the bias field generated by the optimized coil were reduced by 63.2% and 82.8%, respectively.