(765 ILCS 750/15)
    Sec. 15. Affirmative defense.
    (a) In any action brought by a landlord against a tenant to recover rent for breach of lease, a tenant shall have an affirmative defense and not be liable for rent for the period after which a tenant vacates the premises owned by the landlord, if by preponderance of the evidence, the court finds that:
        (1) at the time that the tenant vacated the premises, the tenant or a member of tenant's
    
household was under a credible imminent threat of domestic or sexual violence at the premises; and
        (2) the tenant gave written notice to the landlord prior to or within 3 days of vacating
    
the premises that the reason for vacating the premises was because of a credible imminent threat of domestic or sexual violence against the tenant or a member of the tenant's household.
    (b) In any action brought by a landlord against a tenant to recover rent for breach of lease, a tenant shall have an affirmative defense and not be liable for rent for the period after which the tenant vacates the premises owned by the landlord, if by preponderance of the evidence, the court finds that:
        (1) a tenant or a member of tenant's household was a victim of sexual violence on the
    
premises that is owned or controlled by a landlord and the tenant has vacated the premises as a result of the sexual violence; and
        (2) the tenant gave written notice to the landlord prior to or within 3 days of vacating
    
the premises that the reason for vacating the premises was because of the sexual violence against the tenant or member of the tenant's household, the date of the sexual violence, and that the tenant provided at least one form of the following types of evidence to the landlord supporting the claim of the sexual violence: medical, court or police evidence of sexual violence; or statement from an employee of a victim services or rape crisis organization from which the tenant or a member of the tenant's household sought services; and
        (3) the sexual violence occurred not more than 60 days prior to the date of giving the
    
written notice to the landlord, or if the circumstances are such that the tenant cannot reasonably give notice because of reasons related to the sexual violence, such as hospitalization or seeking assistance for shelter or counseling, then as soon thereafter as practicable. Nothing in this subsection (b) shall be construed to be a defense against an eviction action for failure to pay rent before the tenant provided notice and vacated the premises.
    (c) Nothing in this Act shall be construed to be a defense against an action for rent for a period of time before the tenant vacated the landlord's premises and gave notice to the landlord as required in subsection (b).
(Source: P.A. 100-173, eff. 1-1-18.)