Electromagnetic waves in water

Somewhere I read that submarines and ships use SONAR over radar not just because sound travels so much better under water but because radar can’t be used effectively under water. This apparently is because water restricts its effective range. I can see how effectively light is blocked out at greater depths so how does water affect radar so?

Light and radar are both forms of electromagnetic radiation. The properties of water that allow it to absorb light are the same ones that allow it to absorb radar waves.