We report the first observation of Fano resonance in the Y-shaped cavity (YC), demonstrate that the sensitivity of the sensor is as high as 1160 nm/RIU, much higher than that of the aforementioned sensors, and observe that the quality factor and sensitivity of Fano resonance can be adjusted by changing the geometry of the sensor or adding silver nanoparticles. Traditional sucrose detection methods either waste resources or pollute the environment. This work shows that the sensor can be used to detect the concentration of sucrose. In addition, we found that the concentration of sucrose has a linear relationship with its corresponding refractive index. The sensor we designed can easily and rapidly calculate the concentration of a sucrose solution based on the Fano resonance wavelength shift, which is an important first step towards detecting the refractive index of the solution and identify the composition.