Similar to an electric diode, thermal diode transmits heat in a specific direction, and thermal rectification is also a fundamental phenomenon for active heat flow control. However, in practical applications, thermal rectification will need to be operated under transient conditions. In this study, transient thermal rectification ratio of a one dimensional heterostructure is numerically investigated using the finite element method. Effect of interface thermal resistance, interface initial gap, periodic boundary condition and geometric and material parameters on the transient thermal resistance ratio are obtained. Research indicates that the interface thermal resistance can enhance the thermal rectification effect of the system, and the introduction of the initial interface gap improves the transient thermal rectification ratio by an order of magnitude. The ability to engineer the thermal diffusivity of materials allows us to control the heat flux and improve transient thermal rectification ratio. Since interface thermal resistance can enlarge the difference in heat transfer capability between forward and reverse cases, it is reasonable to suggest that adjusting the interface thermal resistance may also enhance the thermal rectification effect, but excessive interface thermal resistance will reduce it. For periodic temperature boundary conditions, the larger the temperature difference of boundary fluctuation, the larger the fluctuation amplitude of the transient thermal rectification ratio. The fluctuation frequency of thermal rectification is altered along with the periodic boundary frequency, which also affects the amplitude of the fluctuation. Furthermore, by adjusting the initial interface gap, the gap is closed during heat transfer and the interface thermal resistance is reduced in the forward case, while the interface gap is kept open in the reverse case, improving the overall thermal rectification ratio by an order of magnitude. For different transient stages, the equivalent thermal conductivity can be adjusted by adjusting the material and geometrical properties to improve the thermal rectification ratio. As such, the proposed numerical approach and results could be guidance for the optimal design of the transient thermal rectifier.