Yes, if you do it right.
Yes. Sunscreen is designed to block or absorb UV radiation, which is what causes your skin to tan (and burn, and age, and increase cancer risk). So using it properly will prevent tanning to a large degree.
But here’s the catch: no sunscreen blocks 100% of UV rays. SPF 30 filters about 97% of UVB, SPF 50 about 98%. That leftover 2–3% is enough to trigger some pigment production if you’re out all day. Also, most people don’t apply enough or reapply often enough — so they still tan. That’s user error, not the sunscreen’s fault.
Bottom line: if you apply a generous amount, reapply every two hours, and cover all exposed skin, you won’t tan. If you use it sparingly or forget to reapply after swimming, you’ll probably get some color. The sunscreen isn’t lying; you’re just not using it right.
If you want to avoid tanning entirely, stay in the shade or wear protective clothing. Sunscreen is a tool, not a force field.
