A novel strain sensor based on in-fiber Mach-Zehnder interferometer (MZI) is proposed in this paper. The sensor is with the structure of single mode-thin core-multimode-thin core-single mode (STMTS) fiber structures fabricated by splicing two short sections of thin core fiber (TCF) among lead-in single mode fiber (SMF), multi-mode fiber (MMF) and lead-out SMF. The first section of TCF excites the core mode and high-order modes in the core of MMF and the second section of TCF couples the core mode and high-order modes into lead-out SMF to procedure inter-modes interferences. The sensor with MMF length of 20mm and TCFs length of 1mm is fabricated. The transmission spectrum of the sensor with respect to external strain has been studied by experiment. The result shows that the central wavelength respects to external strain with a good linearity. The strain sensitivity of the sensor is -2 pm/ue; over a strain range of 0 to 4500ue;. The temperature response of the sensor is also studied by experiment. The results indicate that the central wavelength of the transmission spectrum is insensitive to external temperature change. The proposed sensor features the advantages of easy fabrication, low cost and high sensitivity, and it exhibits great potential in single parameter measurement.