We grew high-quality epitaxial YBa2Cu3O7 (YBCO) superconducting thin films by the trifluoroacetate route on top of chemical solution deposited SrTiO3 buffer layers. We show that high lattice mismatches can be accommodated in heterostructures grown by chemical methods. Clean interfaces were observed between the different layers. The influence of the buffer layer growth conditions on the final superconducting properties was studied in depth. We have proved that the main parameter affecting the YBCO critical currents is the SrTiO3 surface roughness, which promotes the nucleation of a/b axis grains and, as a consequence, the porosity of the YBCO film. On the other hand, an improved dependence of the critical current with perpendicular applied magnetic field was observed. This suggests a strengthened vortex pinning due to a higher density of a/b axis oriented grains.