How do you let go of a relationship that you know is not good for you?

I am seeing this guy and the relationship isn’t healthy for me. I put to much time and effort and he does but barley minimum but he says he loves me and I’m the most important person in his life but I need to let this go. I need time to think about myself and do things for me.
How do you let go of a relationship that you know is not good for you?
Post Opinion