SrTiO3 (STO) is a widely used photocatalyst for water splitting, which has no photoactivity without a cocatalyst. The reason for this unclear. Here, we performed an oxygen evolution reaction (OER) on clean and oxygen deficient (100), (110), and (111) surfaces on STO by density functional theory. Combining our results with experimental results in the literature, we demonstrated that the overpotential is small enough for OER to occur on (100) surfaces. There is no photoactivity due to the photogenerated holes that cannot migrate to the (100) surfaces. On the (110) and (111) surfaces, the overpotential is very high, which prevents the OER from taking place on these two surfaces. Our work gives a guidance principle to understand the water splitting from the overpotential of OER and migrating photogenerated carriers. It may be helpful to design high efficiency photocatalysts based on STO.