A two-step growth technique was used to achieve effective strain relaxation and dislocation confinement of epitaxial SrTiO3(STO) films and through this to improve their microwave dielectric properties. The crystallization of a very thin quasi-amorphous STO layer deposited at a low temperature in the initial growth step enhanced the strain relaxation from the lattice mismatch at the expense of the formation of high density of misfit dislocations. By varying the thickness of the first layer, different strain states of the films were systematically achieved while keeping the total film thickness unchanged. This allowed the study of the effect of strain on permittivity, and showed good agreement with theoretical predictions. Further more, the two-step growth technique suppressed significantly the threading dislocation density in the film, the dislocations being confined to the first layer. This in turn caused reduction in the extrinsic dielectric loss at microwave frequency. The loss reduction was analyzed and explained based on a dielectric composite model.