And how to avoid the wrong way
A friend/relative/charity needs help. They have little or no money budgeted for the project. You want to help.
Should you work for free? Should you work for friends and family? Yikes. I'm not going to write on either of those topics. Please refer to the 17 million other blog posts and articles already out there.
There's one very simple trick to avoid pitfalls, and keep everyone happy: Treat it like any other paid project for any other very big, deep-pocketed client.
1. Always use a contract. Even if it's your mom.
I had a journalism professor in college who used to over-stress the importance of fact-checking. She used to say (almost daily): "If your mom says she loves you, check it out." In other words, always get additional sources. It's funny. It always got a laugh. But there's a lesson: be a professional, no matter whom you're working with.
A free or low-budget client will expect the same service as a (high budget) paid client. Every time. Use a contract with them for the same reason you use it with anyone. Don't skip this part.
This will help you set clear expectations. Are you working on this project "after hours?" If this is an evenings & weekends project, make sure they know how long it will take (hint: a lot longer than normal, most likely).
2. Make sure they know what you'd normally charge for this service. Show the discount they're receiving.
Send them invoices. Show your discount. You need to continually remind them what you'd normally charge for this work, and what you're charging them. This isn't passive-aggressive. If they don't value your time and energy, they'll have no guilt demanding an endless supply of them.