This is the title of a chapter in Philip Yancey's book "Prayer: Does It Make Any Difference" and a question I have fretted over for a long time.
Here's the basic problem, as stated by Origen, one of the early fathers of the Christian church.
"First, if God foreknows what will come to be and if it must happen, then prayer is in vain. Second, if everything happens according to God's will and if what He wills is fixed and none of the things He wills can be changed, then prayer is in vain."Origen is focusing on the changeless nature of God, His complete knowledge of everything, and His complete power over creation. God knows everything, can do anything, and never changes. What possible place is there for prayer?
Yancey spends a whole chapter (and more) on this conundrum, putting forward a number of ideas. My favorite by far is a quote from C.S.Lewis responding to the question, "If God knows what is best and always does good, then won't He do it whether we pray or not?" Lewis responds,
"Why wash your hands? If God intends them to be clean, they'll come clean without you washing them... Why ask for the salt? Why put on your boots? Why do anything?"Why indeed. I suppose it's an obvious line of thinking, but one I have never really thought about. The question is not so much, "Why does God want me to pray?" as "Why did God arrange creation so that I can manipulate reality at all?"
God doesn't need me to do anything. He is able to do what ever he chooses without my help, and in fact that seems to me to be a more efficient way to get things done. Yet, God consistently chooses to involve me in his world. C.S. Lewis writes, "For He seems to do nothing of Himself which He can possibly delegate to His creatures."