Not necessarily. I think both of them have their own charm, so it's not quite fair to put one above the other overall. Mario's design is more of a happy accident mainly to cater to technical limitations, but it ended up in his favour because it is a memorable design. Plus, he has one of the most fitting voice actors for the character and one of the few that is even used in Japan.
Sonic, by contrast, is designed to be a marketable character by virtue of needing to stand out against Mario. He's also got an attitude that may be irreverent but not extremely so, unlike a good number of imitators (Bubsy comes to mind). The fact that he's SEGA's longest reliable character really speaks volumes on how great Sonic as a character is.
So basically I don't see a point in putting one over the other, but if you ask for my preference, I would say Mario.
Thank you for reading.