Do you have to have exactly 60 cards in a Magic the Gathering deck?
No, not at all. You probably should keep it near the minimum since a deck of minimum size will provide more consistent results than a larger deck, but you are not obligated to do so.


For constructed events, your deck must have at least 60 cards[CR 100.2a] (plus an optional sideboard of no more than 15 cards[CR 100.4a]).
For limited (draft and sealed) events, your deck must have at least 40 cards[CR 100.2b].


Additionally all decks no matter the format must be "able to be shuffled within a reasonable time"

There are many formats that impose additional limitations. Notably,


For Commander games, your deck must have exactly 100 cards (including your Commander)[CR 903.5a].


I could quote you the rules, but Battle of Wits is much more convincing :)



Note: When this answer was originally written the side board was limited to exactly 15 cards. This has changed. I have updated this information to match current rules since it doesn't affect the answer.