At what age should you have your life on track?

Well it's quite different for everyone.
Some have an advantage where it comes to certain aspects and things in general. For example... you have a great upbringing, you get to do what you always wanted, you have stability (mental/emotional/financial etc), you have a loving family etc you would be have more an advantage in life to progress quickly than someone who hasn't had it that easy.
However, I am not saying that people who do not have those things/traits etc won't succeed at whatever level as things can magically change if we want something enough. If you rewire your brain for success. You can go from rags to riches. You can overcome terrible situations and become super successful overnight due to your mindset, your focus and even your determination - that also can be due different timing in your life and when you decide and how strong your intentions are to get there.
Someone can hit a turning point in their teens that they change their life forever...
Someone can make the decision in their 20s when they've had a life changing experience or even 30s, 40s etc
Everyone has different experiences that somewhat mold them into the person they are today. So it depends on the timing of your life and your decision given that point in time.
I am trying to be just and fair in judgement as society has a fucked up way enforcing unrealistic expectations on people when everyone goes at their own pace. They learn their own lessons and do things from a perspective of the way they were taught or their way. Don't be so hard on yourself. You will find your way 😉
Depends where you are trying to get to.
Some things are already closed off to you and in all likelihood were never available to you; for example you are not going to be a world champion athelete, that ship has sailed, if you wanted to be some hot shot lawyer so similar that ship has probably sailed too.
That doesn't mean you can't still train and work as a lawyer but to have a chance to get into the top places you have to be driven all the way through on a straight trajectory and know the right people and probably also be lucky etc.
The long and the short of it is that you make your bed and then you lie in it, whatever that may be.
But it is also never too late to try and do something, you might not be able to become a world champion sprinter but you can still go jogging and make improvements on your personal bests etc assuming you started with and still have your legs etc of course.
You don't say why you're not on track... This isn't the 1800s where you need to apprentice and spend all your working days doing the same thing. If you're working, supporting yourself, you're on track. If you start to feel like you want something more/different. Take time to think. Talk with friends, family. Come up with a plan to achieve when you want next.
Don't be afraid to try something and have it fail. You'll learn along the way. Maybe have some fun.
You said that " I didn’t even plan on living to age 18". You may have some depression. It often helps to talk with someone who isn't family or friends. A mental health professional. Mentor.
Sometimes I volunteer. I find that the activity keeps me from being depressed. I also meet new friends and learn new perspectives on the problems I'm working through.
Opinion
3Opinion
A Korean guy told me that ideally you want your life in order by 30 if not then latest by 35. If it's not in order by then then you seriously messed up and I kinda agree with that.
My 20’s were a lot of hard life lessons and health problems. My 30’s are turning out much better.
You'll wanna get your shit together by your late 20s.
Superb Opinion