As an undergrad I had a friend in the math department who came back to school to get a PhD after some years of making enough $$ to retire on in software. He did not aspire to an academic career. He just liked math and enjoyed spending time on it. He helped us rando undergrads with our problem sets. He is one of the happiest individuals I have ever met. A PhD makes sense at any age for happiness reasons if you don't have financial obligations hanging over you.