Provided herein are compositions comprising lanthanide-doped nanoparticles which upconvert electromagnetic radiation from infrared or near infrared wavelengths into the visible light spectrum. Also provided herein are methods activating light-responsive opsin proteins expressed on plasma membranes of neurons and selectively altering the membrane polarization state of the neurons using the light delivered by the lanthanide-doped nanoparticles.