How to move on from this..

I have been best friends since I was 15 with this guy, I am now 23. We fell for eachother about two years into our friendship but timing was never right, none of his girlfriends & none of my boyfriends liked us being friends so of course respectably we would stop talking, but after breakups we’d talk like we never stopped talking, a couple weeks ago we finally admitted that we love each other and want to give it a try, everything was going well and then he just disappeared.. a few days later, he texted me and said he found out his ex girlfriend is pregnant and he needs to see if they can be happy as a family which I understand but he said maybe in the future if it doesn’t work, which is a no from me. I know I need to move on for good and don’t look back, not only am I losing someone I love, but also my best friend. Any tips on how to do that after this? Thanks for advice in advance