Ultrafast laser-based direct writing of a millimeter long Bragg grating in a microfiber spliced between standard single-mode fibers is presented for highly sensitive temperature measurement. Periodic filamentary voids are written in the core of microfiber using point-by-point inscription method to achieve refractive index modulation. The structural configuration of the sensor offers strong grasp around the microfiber grating when buried in materials of higher thermal expansion coefficients. Any change in ambient temperature causes the molding material to apply higher thermal strain on the grating and amplifies its temperature sensitivity. A maximum temperature sensitivity of 479.48 pm/°C is demonstrated when molded with acetal. The proposed fiber structure can also potentially allow the molding/coating materials to retain strong grip around the fiber in event of adhesion weakening.