“I knew that You always hear Me; but because of the people standing around I said it, so that they may believe that You sent Me.” (John 11:42)
There are some people who refuse to pray in public, because of the warning Jesus gave in Matthew 6 against praying on street corners in order to be seen by men. But although perhaps from sincere motives, these misgivings are not right. There is a place for sincere public prayer — and Jesus modeled it for us here.
The bottom line is: Jesus Himself prayed in public — He did here in John 11 and elsewhere — therefore we can and should as well. It is not prayer in public which Jesus condemned in Matthew 6, but praying for the hypocritical motive of being noticed and admired by others (“SO THAT they may be seen” Matthew 6:5).
In fact Jesus indicates here that there are TWO legitimate motives for praying in public: not only for communicating with God, which is the primary purpose of prayer, but also for the edification of those who are listening. Jesus states here that He prayed out loud specifically “because of the people standing around” so that they might hear His words, and believe!
Hence, praying in public, that others might hear and benefit, is a legitimate endeavor. We should be careful that our public prayers are the “tip of the proverbial iceberg”; and that the majority of our praying is in our closet, in secret, as Jesus went on to command in Matthew 6. But public praying for the benefit of others is not prohibited in scripture. Jesus Himself did it — and we should too.