GaP as well as GaAs has face-centered cubic crystal phase at standard conditions. Despite it, GaP and GaAs nanowires frequently grow in a metastable hexagonal crystal phase called wurtzite. In this work, stable growth of GaP nanowire in the metastable phase is explained by accounting the elastic strain in the nucleus of a new layer. Crystal phase switch in heterostructured Ga(As,P) nanowire caused by heterointerface was studied theoretically and experimentally. Length of wurtzite segment after the switch of crystal phase linearly increases with nanowire diameter. Such dependence can not be explained by only kinetically driven effects. We consider such dependence as an evidence of elastic strain stabilization of the metastable phase in nanowires.