Chameleons change their skin color by using special cells called chromatophores. These cells contain pigment that can expand or contract, allowing the chameleon to adjust the wavelength of light that is reflected off its skin. This, combined with other factors like mood, temperature, and lighting, helps chameleons blend into their surroundings or communicate with other chameleons.