The charity can be practiced with two forms: Private and public. Of course there is no doubt that both forms are good because one important goal of charity is economic benefit that help to reduce the gap between the rich and the poor. The Holy Quran says: “If ye disclose (acts of) charity, even so it is well, but if ye conceal them, and make them reach those (really) in need, that is best for you: It will remove from you some of your (stains of) evil. And God is well acquainted with what ye do.” (2:271)
But between private and public charity which form is recommended? Before answering this question it is nice to refer to a matter of Islamic teachings. Islam teaches us that what is donated in charity will reach God first and it will not get lost. Indeed it is a storing away with The Lord. So, no matter whether anyone is aware or not. Hence, due to God knows it, giving charity in private is better than in public.
In this regard, Imam Sajjad (the fourth Imam of Muslims) has said: “It is more appropriate for you to do privately what you now do in public and keep the affairs between you and Him [God] secret under all circumstances. And you should also not take your hearing and sight as witnesses for the donations that you make in charity as if you have the most trust in yourself. It should not be as if you are not sure that your donations will be returned to you.” (The Treatise on Rights, Right n.13)