Go to bed early enough so that your natural circadian rhythm wakes you up prior to your alarm most of the time. The alarm becomes a backup mechanism. This isn't always feasible due to social obligations (Many people like hanging out late), but if you can do it, it is fantastic.
This is really the best answer. I finally learned to go to bed on time when I had to quit caffeine. It took a couple of weeks for my body to learn to fall asleep and I supported it with calming music (singing bowls and chants at a quiet volume) and not using screens within an hour of bedtime, as well as getting more exercise during the day. The results have been life-changing though. Some words of wisdom: never stay…
That’s wisdom I totally get. Yet, to each their own.