Domains and hosting are separate products with separate billing, and cancelling one does not cancel the other.
IF YOU CANCEL HOSTING BUT KEEP THE DOMAIN
The domain remains registered to you and continues to renew. It will simply not resolve to a website, because the nameservers point at a hosting account that no longer exists. Point it at your new host, or at a parking page, or leave it dormant.
IF YOU CANCEL HOSTING AND WANT TO KEEP THE DOMAIN ELSEWHERE
Transfer the domain out before or shortly after cancelling. Obtain the EPP code, unlock it, and start the transfer at the new registrar. Do this while your Client Area access and contact email are still current.
IF YOU LET THE DOMAIN LAPSE TOO
It follows the expiry sequence and is eventually released to the public. If the domain has any value to you at all, do not let this happen by accident.
EMAIL IS AFFECTED BY BOTH
Cancelling hosting removes the mailboxes. Letting the domain lapse removes the ability to receive mail at that domain at all, regardless of hosting.
Before cancelling either, make sure your Client Area contact address is on a different domain entirely.