A refractive index sensor based on adjusting gap fiber Bragg grating was designed. Spectral characteristics of gap FBG are analyzed based on the coupled-mode theory with the transfer matrix method. As the refractive index of the media in the gap increased, the peak wavelength has a red-shift. Through measuring the reflectivity of the side band, the refractive index of media in the gap can be obtained.© (2010) COPYRIGHT SPIE--The International Society for Optical Engineering. Downloading of the abstract is permitted for personal use only.