In order to get enough sleep, which would be safer, .50 mg. clonazepam before bedtime or .25 mg. Xanax in the morning if I am awakened early. With the help of a doctor I tapered off Xanax, so I don't want to risk having to taper off clonazepam, too.
Both benzos would need to be tapered. It is my opinion that clonazepam is the easier of the two.
As to which of the two is considered "safer" for the reason you wish to take them is something you and your doctor will need to discuss. We are not qualified on this forum to give you that kind of information.
Peace
Greenlydia