The initial heteroepitaxial growth of YBa2Cu3O7-delta films on SrTiO3(001) substrates during pulsed laser deposition shows a growth-mode transition and a change of growth unit. The growth starts with two blocks, each two-thirds the size of the complete unit cell. The first of these blocks grows in a step-flow fashion, whereas the second grows in the layer-by-layer mode. Subsequent deposition occurs layer-by-layer of complete unit cells. These results suggest that the surface diffusion in the heteroepitaxial case is strongly influenced by the competition with formation energies, which is important for the fabrication of heteroepitaxial devices on the unit cell scale.