A real-time sensor based on a lensed photonic crystal fiber (LPCF) is developed for measuring external refractive index (ERI). The sensor head is composed of a LPCF and a micro-mirror encapsulated in a silica tube. The device and the measurement process are extremely simple and fast.