The use of "thou" in church
In the King James Version (KJV) (first published in 1611), the ten commandments read as follows: ten commandments KJV. Most of the commandments begin with "thou shalt".
Although in later versions (for example the English Standard Version from 2001), "thou" is replaced by "you", God is still addressed with "thou" in many prayers.
Bearing in mind that superiors were addressed with "you" (and if one can assume that God is regarded as supreme entity), this seems to be strange.
One could say that this use of "thou" dates back to the time when "thou" was the only pronoun of address for the 2nd pers. sing. and that adhering to this "old" pronoun is part of a tradition.
Furthermore we have to take into account the influence of the original versions of the Bible: The Bible was translated from Latin, Hebrew or Greek, language which distinguish between "tu" (T) and "vos" (V) (T-V-distinction). This distinction was taken over by translating "tu" into "thou". As in the orinigal languages the distinction was not was social status but of number, God was addressed with the singular pronoun (T) (cf. Barber, 210).
Another argument for addressing God with "thou" could be that "thou" expresses familiarity and proximity; feelings which many people have when the address God in prayers.