It will depend on the length of your tenancy agreement. The most common fixed period is 6 months, after which the tenancy runs on a month by month basis.
In this instance you would be obligated for the first 6 months, and should you wish to vacate you would need to give one months notice in writing, ending no sooner than the initial 6 months.
Should you decide to stay beyond the initial 6 months then this is perfectly acceptable, depending on what your landlord also requires you can either continue on a ‘statutory periodic tenancy’ running on a month by month basis on the same terms and conditions or sign another fixed term contract.
If the landlord requires possession of the property then they would need to provide you with normally 2 months notice (currently 6 months notice under Covid rules), which cannot expire sooner than the initial 6 month fixed term.