Beyond negotiated exits, most legal systems recognize certain circumstances that let a tenant leave early with reduced or no penalty, though the specific list varies by country, so treat these as categories to check locally rather than guarantees. The strongest ground almost everywhere is the landlord's own breach: if the property is uninhabitable, no heat or water, serious mold, structural danger, or illegal entry and harassment by the landlord, and written complaints go unfixed, many jurisdictions let you terminate for cause, and documentation of the defects and your complaints is what makes it stick.
Several countries recognize hardship grounds, job relocation, job loss, serious health issues, or admission to care, sometimes with shortened notice rather than full release. Special statutory protections exist in various places for specific situations, such as domestic violence victims or military deployment.
Process determines outcomes here: put problems in writing early, give the landlord a documented chance to fix them, keep dated evidence, and follow the exact notice formalities your local law requires.