Yes, but you want to be in a position to do so when you need to.
I canceled all my credit cards two years ago, and am currently in a lot of debt, so my credit is probably awful.