When you're talking about someone receiving something directly, use it to follow the recipient (the person who receives something). Every year I give a birthday gift to my dog. If you're talking about the reason or purpose behind doing something—but not the actual giving—use it for
If you're confused about when to use "to" and when to use "for" with purpose, you're not alone. It's a common mistake that even native speakers make. But don't worry, once you understand the difference, it's easy to get it right.
Here's a quick rule of thumb: "To" is used when the purpose is a verb, and "for" is used when the purpose is a noun.
Let's look at some examples to see how this works in practice.
If you want to buy a gift for someone, you would say "I'm going to the store to buy a gift for my friend." In this case, "to buy" is the verb, so we use "to."
But if you want to buy a gift because you think it will make the recipient happy, you would say "I'm going to the store for a gift for my friend." In this case, "to make the recipient happy" is the noun, so we use "for."
Here are some other examples:
As you can see, it's pretty straightforward once you know the rule. So next time you're not sure which one to use, just ask yourself if the purpose is a verb or a noun. If it's a verb, use "to." If it's a noun, use "for."
And that's all there is to it!