This paper proposes a novel solution to the inverse problem of eddy current nondestructive testing (NDT) based on topological shape optimization. The topological gradient (TG) is derived for a steady state eddy current problem using a topological asymptotic expansion for the Maxwell equation of a time harmonic problem. TG provides information on where the objective function is most sensitive to topology changes and can be used as a fast identification of the locations of the defects in the test specimen. The proposed method has been applied to typical eddy current testing (ECT) problems such as buried crack reconstruction and the detection of multiple cracks. The reconstructed shape of the crack shows good agreement with the experimental data from TEAM workshop problem 15. A comparison of different ECT inverse analyses is also discussed.