Ugh, yeah, that's gotta hurt a lot. Sorry to hear that. Unfortunately, this is one of those things where there are no quick, easy fixes - it's gonna hurt for a while, and mostly you need time.
You've got the right intuition here, though: He is not interested in a romantic relationship with you, and you need to move on eventually. It's okay if it takes a while, it's okay if it hurts. It's okay if you can't handle friendship right now. But he's not coming back, so you're right, you need to move towards rediscovering the happily single person you were.
What did you do back then? With what did you fill your time? What were the friends you leaned on? If you don't naturally feel happily single, you can still act like a person who is, and your emotions will catch up eventually. Fake it 'til you make it, basically. It's standard breakup advice for a reason.
Do you need to cut contact with your ex for a while? It is okay to tell him that you understand the permanence of the breakup and therefore need time to get over it, so you need to stop contact for... three months? I don't know what feels reasonable for you. For me, this period of no contact has been absolutely key to keeping sane and eventually recreating friendship.
You'll be okay. You just need time to heal. Hugs, if you want them.