First off, the criteria for unlocking characters can be found here: https://www.ssbwiki.com/Unlockable_character Secondly, this used to be in a forum. The guide was posted by pika250, so I thought I'd post it here. It's narrated from his point of view. Finally, a more specific route to the Wii U smash bros can be found here. https://www.speedrun.com/ssbwiiu/guide/al5du
Melee (part 1):
Start a 1 stock vs match, items off, with 4 different characters, on a safe stage with no hazards (e.g. Yoshi's Story). Make sure one of these characters is a character you want to use to unlock Mewtwo. Keep in mind that you will be using two characters to unlock characters in vs mode (Marth being the second), so save another character for that point as well. Once you start the match, move on to completing all the other games.
After that, the other 3 games can be done in any order. I listed them in the order they were released, but the order of completion really doesn't matter.
Smash 64:
I would recommend trying to unlock Ness first (Normal, 3 stock, no continue). That way, if you fail it (e.g. game overing), you can finish that run and unlock Falcon or Jigglypuff, and try again. I would also recommend doing the Break the Targets as you go in the 1p mode so you don't have to do it later for Luigi (unless you repeat a character, then only do it the first time). I'd save Luigi for last so that you do some of the BtT during the 1p mode (saves about 30 seconds overall, very rough estimate).
Brawl:
As far as routing goes, without versus matches, you would have to complete Subspace Emissary to unlock all characters, as "complete Subspace Emissary" is a requirement to unlock some characters. As you're going through Kirby's solo Subspace section, make sure you pick up Link and Zelda, as that unlocks Ganondorf. After completing Subspace, you'll be left with Jigglylpuff, Toon Link, and Wolf. You can either return to Subspace or do their alternate requirement method (I'm not sure how far into the stage they get unlock in Subspace, so I'm not sure which is fastest).
Smash Wii U:
I would recommend doing All-Star on Normal first (unlock Dark Pit), since every character you unlock adds another character to the all-star run. I would also recommend doing Crazy Orders last (unlock ROB), as you may earn Crazy Order tickets and gold along the way, giving you more attempts at meeting his requirements. Otherwise, the order in which you complete all the unlock requirements is more or less up to you. Again, like in Smash 64, when doing the Classic mode unlocks, I would recommend doing the higher level requirement first, as if you Game Over, it will still qualify for the lower requirements. Another thing to consider is that since Game Overing makes your difficulty go down by 0.5, if you are worried about game overing, you can do the 5 classic modes on difficulty 2.5, giving you a one Game Over buffer in case something goes wrong.
Melee (part 2), splitting up into paragraphs due to complexity:
When you come back to melee, just sd on 3 characters, making the character you want to have face Mewtwo win the game. Then just unlock Mewtwo. While still in versus mode, you can unlock Marth by playing a vs mode with each of the original 14 characters, so just play 2 more 4 person vs mode matches, and a final 2 person match to get all 14, making the winner of the last one the one you use to face Marth.
I would recommend saving the event match requirements for "last" (Ganondorf and Pichu), as Pichu's event requires several characters to be unlocked. I would also recommend completing any Break the Targets you end up doing in classic modes along the way, as all Break the Targets will be the fastest method for Game & Watch.
Aside from that, again, the order you complete the other modes is entirely up to you. I would recommend that any "Adventure or Classic" mode requirements be done in Classic, as Classic is much faster than Adventure, and you need to complete 10 Classic runs to unlock Young Link anyways. Aside from that, whether you start with Classic (Jigglypuff, Dr. Mario, Young Link, Roy), Adventure (Luigi), or 100 man melee (Falco), is entirely up to you (if a character in one mode is a character you'd prefer to use in another, e.g. Jigglypuff in Adventure, then you can do Classic before Adventure).
Once every character aside from Mr. Game & Watch is unlocked, complete the Break the Targets with all remaining characters (i.e. characters you didn't complete classic mode with). Then you unlock Mr. Game & Watch, and finish the run.