Tanning under the sun or using a solarium can cause irreversible damage to skin cells. A tan therefore is not a healthy glow, but skin cells in trauma trying to protect themselves against damage that can start a melanoma growing. Sunburn can kill skin cells altogether.
The ability to tan varies between people; some burn or tan more easily than others. A tan can provide weak protection against sunburn, only about as much as an SPF3-5 sunscreen, depending on skin type, but a tan does not protect against skin damage.
Although a tan is visible, UVR also causes damage in the skin cells which can’t be seen. This damage adds up over time, and can lead to skin cancer, so it is important to minimise exposure to UVR.