To add to the previous post:
Sonic does appear in those games, but that doesn't make the rest of the sonic universe(s) a nintendo franchise.
in order to be a nintendo franchise, you need at least some of the following points:
* The franchise needs to be owned by nintendo, or one of it first- or second-party associates
* The development team of each game in the series needs at least some input from the seniors at
* Each game needs it's premium release on a Nintendo console, usually because of a Exclusivity clause in a contract that is somehow related. This doesn't apply to minor ports
(it varies from franchise to franchise which criteria is met)
For instance:
* Pokemon - developed by Game Freak, published by Nintendo and realease only on Nintendo Consoles
* Mega Man - developed and published by Capcom, initially developed only for Nintendo games, it is no long a "Nintendo Franchise" once it was published on a Playstation.
* Sonic - developed and published by Sega, now showing up in all three current-gen systems. Sonic shows up in side games, such as Olympic Titles, and Smash bros because Nintendo worked out a deal with Sega and because Both companies new that Mario-vs-Sonic is one of the biggest rivalries in gaming and therefore would be something the fans would like.
* Ace Attorney - developed by Capcom, published by Capcom and Nintendo Austrailia, only realeased on Nintendo Console, except for the minor iPhone ports which didn't add much to the story.
* Mario - developed and published by nintendo, released only Nintendo-systems since the mid-nineties
* Zelda - same as Mario
Even though many of these franchises have involved 3rd party companies (Snake from Konami being in smash bros, Link being in Soul Caliber 2) the franchise is usually associated as a whole with nintendo.