How do you deal with insecurity about being lonely and living alone?

So i have moved on from a group of toxic friends around me.I feel I am more relieved and independent now but you know it hurts more when people points you out for living alone and having no friends.This feeling kind of ruins my mental state and put me into a guilt trip somehow .So how do i deal with these kind of people and negative thoughts that surrounds me when something does not go well.