Quantum computing is a new way to process quantum information by using superposition and entanglement of the quantum system. Quantum state’s vast Hilbert space allows it to perform operations that classical computers cannot. The quantum computing has unique advantages in dealing with some complex problems, so it has attracted wide attention. Computing a single qubit is the first of seven fundamental stages needed to achieve a large-scale quantum computer that is universal, scalable and fault-tolerant. In other words, the primary task of quantum computing is the careful preparation and precise regulation of qubits. At present, the physical systems that can be used as qubits include superconducting qubits, semiconductor qubits, ion trap systems and nitrogen-vacancy (NV) color centers. These physical systems have made great progress of decoherence time and scalability. Owing to the vulnerability of qubits, ambient thermal noise can cause quantum decoherence, which greatly affects the fidelity of qubits. Improving the fidelity of qubits is therefore a key step towards large-scale quantum computing. Based on the dipole field driven qubit, the stochastic dynamic structure decomposition method is adopted and the Kubo-Einstein fluctuation-dissipation theorem is used to study the qubit control in a thermal noise environment. The dipole field has components in three directions, not just in one plane, which allows more flexible control of quantum states. Without considering the noise, the quantum state can reach the target state 100%. In the noisy environment, thermal noise will cause the deviation between the actual final state and the target final state caused by thermal fluctuation, which becomes the main factor affecting the quantum fidelity. The influence of thermal noise is related to temperature and the evolution trajectory of quantum state. Therefore, this paper proposes an optimal scheme to improve the qubit fidelity in the thermal noise environment. The feasibility of this method is verified by numerical calculation, which can provide a new solution for further guiding and evaluating the experiment. The scheme is suitable for qubit systems of various physical control fields, such as semiconductor qubits and nitrogen vacancy center qubits. This work may have more applications in the development of quantum manipulation technology and can also be extended to multi-qubit systems, the details of which will appear in the future work.