With its citadel and its castle, Kerak is an ideal place to stop off, half way along the road between Amman and Petra.
My suggestion
There isn't much accommodation on offer in Kerak, and it's not worth spending the night there. Simply stopping and exploring is sufficient, arriving on the journey from Amman and continuing toward Petra.