Nanoscale grain and high dislocation density are the most common microstructures of nanocrystalline NiTi alloy. Although grain size and dislocation density influence the functional properties of NiTi alloy significantly, their effects on martensitic transformation have not been investigated quantitatively. In this work, the effects of grain size and dislocation density on thermally-induced martensitic transformation of nanocrystalline NiTi alloys are studied based on experiment, molecular dynamics simulation and theoretical analysis. Firstly, the drop of martensite-start-temperature and austenite-finish-temperature with decreasing grain size is determined, which is attributed to the increased fraction of grain boundary and the enhanced disordering of austenite near grain boundary via molecular dynamics simulation. Secondly, the positive correlation between dislocation density and transformation temperatures is verified by experiments and molecular dynamics simulations, which is ascribed to the enhanced stability of correspondence variant pair with habit plane of (−0.4138 0.8684 0.2688) and invariant shear direction of [−0.4432 −0.458 0.77706] under the dislocation-induced stress field. At last, a novel thermodynamic model of nanocrystalline NiTi considering grain size and dislocation density is proposed to predict martensite-start-temperature and austenite-finish-temperature. Prediction results accord to experimental data reasonably with the error generally less than 15 K. This study provides a basis for regulating the functional properties of nanocrystalline NiTi alloys through microstructural manipulation.