Mechanoluminescence (ML) featuring photon emission by mechanical stimuli is promising for applications such as stress sensing, display, and artificial skin. However, the progress of utilizing ML processes is constrained by the limited range of available ML emission spectra. Herein, a general strategy for expanding the emission of ML through the use of lanthanide emitters is reported. A lithium-assisted annealing method for effective incorporation of various lanthanide ions (e.g., Tb3+, Eu3+, Pr3+, Sm3+, Er3+, Dy3+, Ho3+, Nd3+, Tm3+, and Yb3+) into CaZnOS crystals that are identified as one of the most efficient host materials for ML is developed. These doped CaZnOS crystals show efficient and tunable ML spanning full spectrum from violet to near infrared. The multicolor ML materials are used to create encrypted anticounterfeiting patterns, which produce spatially resolvable optical codes under single-point dynamic pressure of a ballpoint pen.