Over the years you plan to stay, is it cheaper to keep renting or to buy? Compare the real cost — deposit, mortgage and the equity you build — and find your break-even year.
An estimate, not advice. Assumes a 25-year mortgage, ~7% purchase costs (DLD, agent, mortgage) and ~2% to sell. It doesn't model the return you'd earn investing the deposit instead, or maintenance beyond the service charge — real factors, so treat the break-even as a guide. Change any figure to match your situation.