You learn not to give a shit and realize work isn't all there is to life. IOW you develop a more balanced, informed world view. You also learn to not do stupid shit, which saves a lot of effort.
Age happens to be the only way to obtain life experience, unfortunately, although the reverse is not true - a lot of people never actually learn of the deeper issues in their lives in that meta-cognitive way. Some just keep doing things more or less the same way they had done them when they were 20. That is a recipe for much regret on one's deathbed. One thing that helps profoundly to understand one's life in a deeper context is raising kids. You see exactly what you were at any given age, and you see the shortcomings (and sometimes advantages) of behaving that way. So you learn much more effectively. It's not the same if it's someone else that you can't observe 100% of the time, without a "facade".