The salt resistance property and microstructure transition induced by divalent metal ion of wormlike micelle formed in mixed zwitterionic (N-tetradecyl-N,N-dimethyl-3-ammonio-1-propanesulfonate, TDAPS) and anionic (sodium dodecyl sulfate, SDS) surfactant system are investigated by rheological measurement. It has been found that the viscoelastic and anti-shearing properties of this wormlike micelle system are not reduced but reinforced in the total concentration of Mg2+ and Ca2+ range of 0 similar to 1900 mg/L upon adding MgCl2 and CaCl2. A further analysis of the rheolgical measurement results show that two distinct length wormlike micelles coexist in this system. During the addition of divalent metal ion, a transition from small wormlike micelle to large wormlike micelle takes place, and the large wormlike micelle grows linear and branched at the same time. The positive charge on the zwitterionic surfactant headgroup reduces the binding efficiency of the wormlike micelle, and inhibits the microstructure transition, which endows the high salt resistance property of this system.