Relationships take hard work, and in spite of your best efforts, it might not work out. Sometimes people grow apart or they take each other for granted and stop nurturing the relationship.
Not every couple like to admit to themselves or want to let others know that they cannot make it work, so they stay together even when they are both miserable.
There is no point in holding on if you are not happy. There is nothing you can gain from staying stuck in unhappiness. Sometimes when you have given it your best shot, and it is not working out, you have to let go. Walk away. It is better to be alone than to stay stuck in an unhappy relationship.