Although electromagnetic waves have many uses, they can also be dangerous. Different types of EM wave can be dangerous in different ways.
Microwaves
Because microwaves have a heating effect, some powerful microwaves can be dangerous. Your microwave oven will not switch on if the door is open, to prevent the microwaves causing damage to the cells in your body by heating them.
Infrared
The heating effect of infrared waves can cause burns to your skin.
Visible light
Concentrated visible light (eg from a laser or the Sun) can cause eye damage or even blindness.
Ultraviolet
Ultraviolet (UV) radiation can cause eye damage, which is why most sunglasses can absorb UV, preventing it from reaching the eye. The intense UV emitted by the Sun is absorbed by your skin and can cause sunburn or even damage DNA in your body cells – which could lead to skin cancer.
X-rays
X-rays can also damage DNA in body cells, which could lead to cancers developing inside the body. For low levels of exposure (eg a few medical x-rays per year) this is not a significant problem, but radiographers and other people working with X-rays must take precautions to reduce this risk.
Gamma rays
Like X-rays, gamma rays can also damage DNA in your body cells which can lead to cancers developing inside the body. People working with radioactive substances which emit gamma rays must limit the amount of gamma radiation they are exposed to, by wearing protective clothing and restricting the time they work near these materials.