What can cause red hard and tender to touch areas on the outter part of ankle?

Gout. Although it could be other things, what you are describing sounds like gout. Take ibuprofen and see a doctor. There are medicines available for gout. If not gout and not an injury, it could be a skin infection or bug bite that got infected.
Interesting?? For a 40 yo with this presentation it would be helpful to see a picture. Possibly psoriasis. Recommend a doctor evaluation for definitive diagnosis.