Due to the fact that it is possible to manipulate light with photonic crystals (PCs), PCs hold a great potential for designing new optical devices. There has been an increase in research on tuning the optical properties of PCs to design devices. We presented a numerical study of optical properties of metamaterial-based devices by liquid crystal infiltration. The plane wave expansion method and finite-difference time-domain method for both TE and TM modes revealed optical properties in photonic crystal structures in an air background for a square lattice. E7 type has been used as a nematic liquid crystal and SrTiO 3 as a ferroelectric material. We showed the possibility of the metamaterials for a two-dimensional photonic crystal cavity on a ferroelectric base infiltrated with a nematic liquid crystal.