Yes, both OK and essentially synonymous. I suppose that 'to' is more direct to the charitable organization, where 'for' may open the possibility of an intermediary.
New words, one handy idiom, and a 2-minute quiz — delivered to your inbox to keep your streak alive.
CliveI gave money for TomClive, it sounds like I gave money on behalf of Tom. What do you think?