The three-dimensional instability of an electrically conducting fluid between two parallel plates affected by an imposed transversal magnetic field is numerically investigated by a Chebyshev collocation method. The QZ method is utilized to obtain neutral curves of the linear instability. The details of instability are analyzed by solving the generalized Orr-Sommerfeld equation. The critical Reynolds number Rec, the stream-wise and span-wise critical wave numbers αc and βc are obtained for a wide range of Hartmann number Ha. The effects of Lorentz force and span-wise perturbation on three-dimensional instability are investigated. The results show that magnetic field would suppress the instability and critical Reynolds number tends to be larger than that for two-dimensional instability.