I’ll piggy back on your comment, I was gonna say something similar (and I fully agree with it 😊)
With only the information you provided, it sounds like you’re potentially navigating some high functioning depression, maybe some meaninglessness. They can go hand in hand, and much of the joy of life is lost when/if you’re depressed with no personally meaningful direction.
Therapy is a good starting point, or even just some gentle self analysis of what may have led you to these feelings (as opposed to the symptoms of it, which it looks to me like what you described).
It’s a process, and it can take a very long time to learn how to be gentle enough to listen to yourself without judgement. So in addition to therapy, I’d add meditation to allow yourself space and journaling with personally directed questions (e.g., what do I feel, what may have led me to feel this way) that might grant you insights. Dig for what means something to you, and find a way to make it your reality.
One final thought - do try getting out there and connecting. It’s hard, irritating, and exhausting. But sometimes we spend so much time in our own space/heads that we ruminate ourselves into a quagmire. Ppl and activities corner that rumination to fewer hours of the day, and gives us a break from our own thoughts.
As poster above said, you’re not even 40 - lots of years of beauty, hope and meaning to be found and loved, though it can take time to really get there :)
All the best, OP
This was the perfect balance of sardonic response and 90s/early 2000s