Because it takes away all your thoughts, and connects you with instant reality. Plus, it's a fitness activity, it is insanely fun, very social and gives an intense sense of achievment.
There are risks inherent to climbing, but I would not agree that it is incredibly dangerous. In the US, an average of 30 people die annually in climbing accidents. It's difficult to find a denominator to put that number in perspective, but somewhere on the order of a million people climb outdoors each year in the United States and about 5 million participate in indoor climbing. I feel far less safe biking to my climbing gym than I do climbing.