The spacecraft attitude control is carried out using the to-go quatemion. A derivative of the to-go quaternion is derived where the desired attitude is a time dependent function. Based on this new attitude formulation, a proper state dependent coefficient matrix expression is obtained. Then the nonlinear tracking attitude control is realized using the state dependent Riccati equation method. The simulation results are given and discussed.