An example of
nonqualified use of your home
before you stopped living in the home as your main residence is if you had 2 homes and lived in both homes off and on during the 5 years prior to the sale of this home. In this case, you'd answer
Yes here because you had periods of nonqualified use of this home you're selling (while you lived in the other home) and the nonqualified use happened
before you stopped using this home as your main residence.
If you lived in your main home and then converted it completely to a rental and no longer lived in the home, you'd answer
No because the nonqualified use (while it was used as a business) was
after you stopped using the home as your main residence.