If you and your partner have made a decision about who is going to stay in the property in the long term, you may need to change the name on the tenancy agreement. If your partner is the sole tenant and they leave, your landlord can evict you unless you have the tenancy changed into your name.
Tenants can transfer a tenancy by assignment, or by asking the landlord to give a new tenancy to the partner who is staying, and then surrendering the tenancy themselves. Not all tenancies can be assigned, and some tenancies can only be assigned to certain people. Check to see what your tenancy agreement says. A landlord is also not obliged to grant a new sole tenancy to the remaining partner. It is best not to end a tenancy before getting written agreement from a landlord that a new tenancy can be created for the remaining partner.
It is worth remembering that if you are granted a new sole tenancy, you will have to cover all the rent and maintenance costs yourself. It is worth drawing up a budget to make sure the costs are affordable. If not, you may be able to get maintenance payments or benefits to help with housing costs.