In this work, metal ion-induced viscoelastic wormlike micelles in anionic/zwitterionic surfactant solutions (sodium dodecylsulfate/tetradecyldimethylammoniumpropanesulfonate, SDS/TPS) are reported. Steady and dynamic rheology and cryogenic transmission electron microscopy (cryo-TEM) are employed to characterize wormlike micelles in the SDS/TPS/Ca(NO(3))(2) system. Moreover, the surfactant mixing ratio and surfactant tail length are varied to reveal the factors that influence wormlike micelle growth and solution viscoelasticity. A series of metal ions such as Na(+), Mg(2+), Zn(2+), and Al(3+) are proven to promote viscoelastic wormlike micelle formation in the SDS/TPS system. The metal-containing wormlike micelles are expected to be good candidates for directing the synthesis of inorganic nanomaterials. In this article, dendritic silver nanostructures have been prepared in the surfactant wormlike micelle by in situ UV irradiation for the first time.