All perfect praise be to Allaah, The Lord of the Worlds. I testify that there is none worthy of worship except Allaah, and that Muhammad is His slave and Messenger.
Sun gazing is an imitation of the non-Muslims who worship the sun. Saying that sun gazing has benefits is an unfounded claim. It is known that gazing to the sun is harmful to the eyes even if it is done immediately after sunrise or just before sunset as we were informed by the doctors.
Therefore, one should not gaze at the sun for a long time as this is an imitation of the non-Muslims. This act may even be forbidden if it harms the eyes, and it may even be an act of Shirk [associating partners to Allaah] if this is accompanied by some sort of belief in that.
For more benefit, please refer to Fatwa 85297.