In fact, it's fair to say the Alliance of Lordaeron would never have existed if the Kingdom of Azeroth (Stormwind) hadn't fallen to the Horde in the First War. Lothar's desperate journey away from the ravaged capital of the southern human kingdom with the child king Varian Wrynn in his arms and his arrival in Lordaeron at Terenas' court is the stuff of legends now, but then it was a very near thing, a flight from bloodthirsty marauders who dogged their heels at every step and could easily have caught and killed them all. Even after Lothar made that dread trip north and roused the other human kingdoms, got Terenas on board, convinced the dwarves, gnomes and elves to join up (and even there, the Horde helped by doing things like recruiting the Trolls and attacking Quel'Thalas) the lack of unity in the Alliance of Lordaeron nearly cost it the Second War, Alterac being the most obvious example. If not for Gul'dan's treachery, in fact, the Horde most likely would have won the Second War and destroyed the Alliance of Lordaeron.
The aftermath of Gul'dan's decision to take the Stormreaver and Twilight's Hammer and go get eaten by demons at Sargeras' tomb was that the Alliance finally had the chance to push the Horde back, confronting Doomhammer and his forces at Blackrock Mountain, where Lothar met his death and Turalyon took up his shattered sword, defeating the Orcs and capturing or pushing them back through the Dark Portal. While the Alliance managed to exist long enough to mount the Alliance Expedition to Draenor following Ner'zhul and Teron Gorefiend's theft of the Book of Medivh, it disintegrated into squabbling and infighting not long after as Genn Greymane pulled out entirely over the question of letting the Orc prisoners from the Second War live in internment camps rather than exterminating them.
It's also necessary to mention the effect Daval Prestor had on the Alliance at this time. An unknown nobleman claiming relation to the deposed Perenolde dynasty of Alterac, he nearly managed to get himself married into the Lordaeron royal family and placed on the throne of Alterac at the same time. Luckily for Calia Menethil, for some reason Daval Prestor disappeared and she never had to marry him. Unfortunately for Alterac, this left the place to the mercies of the ogres and the Syndicate.
Ironically, the Alliance as a cohesive entity basically didn't exist during the Third War. Ner'zhul as the Lich King struck at Lordaeron alone, using Kel'Thuzad (a former archmage of Dalaran) to help corrupt Prince Arthas, who sailed to Northrend sans his father's approval after the atrocities at Stratholme, and returned, Frostmourne in hand, to slay his father and destroy his kingdom. The loss of Lordaeron and the creation of the modern Plaguelands spelled the end of the Alliance of Lordaeron as it stood, as did the destruction of Quel'Thalas and the pollution of the Sunwell to raise Kel'Thuzad as a Lich. The destruction of Dalaran followed hard upon. Jaina Proudmoore's flight to Kalimdor helped sever Kul Tiras from the remnant as well, as Admiral Daelin Proudmoore soon took the Navy to find her. This left a rebuilding Stormwind in no position to take action against the Burning Legion and the Scourge, and ragged bands of survivors throughout the Plaguelands under the command of men like Garithos acting on their own.
Meanwhile, the remnants of the Alliance under Jaina found themselves at first in conflict with, and then allied to, the Night Elves of Kalimdor. To this motley alliance were added the orcs, trolls and tauren under the young Horde Warchief Thrall, after subtle and not so subtle meddling by Medivh himself, no longer insane or possessed by Sargeras (and also no longer dead) - this assortment of mortals stood against the Burning Legion and its advance up the slopes of Mount Hyjal, but they fought at best a delaying action to give Malfurion Stormrage time to take action and make the ultimate sacrifice, destroying the World Tree Nordrassil and the night elves' immortality in the process.
To be honest, how we get from this moment to the current state of affairs between the Horde and Alliance is kind of vague. Part of it can be laid at Grom Hellscream's feet: while he and Thrall stood together against Mannoroth and earned Grom a hero's death, his previous actions in Kalimdor (drinking Mannoroth's blood in a tainted fountain and slaying Cenarius, the demigod patron of the druids and teacher of Malfurion himself) had earned the orcs a lasting enmity from the kaldorei. The Warsong Clan's further expansion north into night elf lands stoked the fires of hostility, and it's fair to say that without the actions of Grom and his Warsong Clan, the night elves would have had no compelling reason to join the new Alliance that rose after the Third War. Likewise, with the Scourge having destroyed Lordaeron by this point, human power was at its lowest ebb.
Gilneas remained sealed behind its wall, Dalaran was destroyed, Kul Tiras bereft of its ruler and most of its navy, Alterac a blighted land of thieves and ogres, and Stromgarde (already weakened by Thrall's campaign to free the orcs that destroyed Hammerfall and Durnholde Keep in occupied Alterac) found itself overrun with Syndicate from Alterac and ogres as well. This left only the former Kingdom of Azeroth (now calling itself Stormwind) as having any power and influence of the original seven, and Theramore Isle in Kalimdor populated by various refugees from the destroyed nations consumed by the Scourge and the Legion. We're still not aware of what, exactly moved the dwarves and gnomes to join the Alliance following the Third War (although we know the fall of Gnomeregan is what kept the gnomes out of the Third War) aside from general hostility from the Second towards orcs and trolls. It's possible one strong motivation to join was the existence of the Forsaken to their north, almost indistinguishable from the Scourge and slowly moving south through Silverpine Forest and the ruined lands of Alterac. Once the Forsaken joined the Horde, it only became more compelling to be part of an organization that could oppose them, one suspects.
At present the Alliance stands more united than ever. The admission of the shipwrecked draenei gave the night elves a closer ally in their attempts to reclaim Ashenvale and protect it from Legion demons and Horde incursions alike, as well as helping the Alliance make inroads with native draenei and lost ones in Outland. The return of Varian Wrynn spurred the Alliance into Northrend, where for the first time night elves, humans, gnomes and dwarves can all be seen fighting side by side against the Scourge and the Horde alike. Muradin Bronzebeard's return from seeming death has had a similar effect for Alliance unity, as has the more bellicose attitude of Garrosh Hellscream, Overlord of the Warsong Offensive and son of Grom, slayer of Cenarius. The very legacy of the Old Horde that serves to often unite the Horde seems often to unite the Alliance even more effectively.
Next week, we'll talk about the cost of all this: the deaths and worse of the Forsaken, the xenophobic betrayal of the Quel'dorei and their transformation into blood elves, the redemption of the orcs and their pacts with tauren and troll allies that helped create the New Horde from the ashes of the Old.