Hydroxyapatite (HAp), Ca10(PO4)6(OH)2, is known to precipitate on bioactive materials by soaking in simulated body fluid (SBF). The formation of HAp on TiO2 and CaTiO3 surfaces under continuous ultraviolet (UV) irradiation was investigated in this study. Pure Ti substrates were chemically treated with H2O2/ HNO3 solution at 353 K for 20 min to form a TiO2 gel layer. The samples were then hydrothermally treated with an aqueous NH3 or an aqueous Ca(OH)2 solution in an autoclave at 453 K for 12 h. An adhesive and sufficiently crystallized anatase-type TiO2 film or perovskite-type CaTiO3 film could be synthesized on the Ti surface, respectively. The samples were immersed in SBF in darkness or under UV irradiation. The UV irradiation promoted the formation of HAp, which may be due to the generation of functional Ti-OH or Ti-O groups on both surfaces. On the other hand, the UV light also produces electron-hole pairs in the product films. In TiO2, much photogenerated holes migrated to the surface and repelled the Ca2+ ions in the solution. As a consequence, the UV irradiation suppressed the formation of HAp thin film on the surface of TiO2.