What if the great events in history had turned out differently? How would the world today be changed?

Niall Ferguson wonders about this a lot. He's a well-known economic historian at Harvard, and a champion of "counterfactual thinking," or the re-imagining of major historical events, with the variables slightly tweaked. In a 1999 book Virtual Histories, Ferguson edited a collection of delightfully weird counterfactual hypotheses. One essay argued that if Mikhail Gorbachev had never existed, the USSR would still exist today. Another posited an alternative 18th century in which Britain allows its colonies to develop their own parliaments – so the Americans never revolt, and the USA never exists.

The essays were fun, but Ferguson really craved a more holodeck-like experience. He wanted to have a computer simulation that would let him set up historical counterfactuals – based on real-world facts – and then sit back to see what happens. "I was always thinking that one day the right technology would come into my life," he told me.

Last year, it finally did. Ferguson was approached by Muzzy Lane, a game company that had created Making History – a game where players run World War II scenarios based on exhaustively researched economic realities of the period.

As he played it, he realized the game was good – so good, in fact, that it forced him to rethink some of his long-cherished theories. For example, he'd often argued that World War II could have been prevented if Britain had confronted Germany over its invasion of Czechoslovakia in 1938. France would have joined with Britain, he figured, pinching Germany between their combined might and that of the Russian army. "Germany wasn't ready for war, and they would have been defeated," he figured. "War in 1938 would have been better than war in 1942."

But when he ran the simulation in Making History, everything fell to pieces. The French defected, leaving Britain's expeditionary force to fly solo – and get crushed by Germany. His theory, as it turns out, didn't hold water. He hadn't realized that a 1938 attack would not leave Britain enough time to build the diplomatic case with France.

The game, in essence, helped him think more clearly about history. "I found that my scenarios weren't as robust as I thought. And that's really exciting, because normally counterfactuals happen in my head," he says. "Now they can happen on the screen."

Ferguson discovered something that fans of war-strategy and civilization-building "god" games have realized for years: Games are a superb vehicle for thinking deeply about complex systems. After you've spent months pondering the intricacies of the weapons markets in Eve Online, or the mysteries of troop placement in Company of Heroes, you develop a Mandlebrotian appreciation of chaos dynamics – how a single change can take a stable situation and sent it spiraling all to hell, or vice versa.

Though Ferguson couldn't figure out how to make his 1938 scenario work, there was a better expert who could: His 13-year-old son, who was a whiz at strategy games. Rather than rush out to attack Germany, his son carefully set up robust trade agreements with France first to make sure the country felt diplomatically obligated to go along with the fight. Presto: France fought, and Germany fell.

Ferguson became so delighted with Making History that he has joined forces with Muzzy Lane to design a new game. Due out in 2008, this one will model modern, real-world conflicts such as Iraq, Afghanistan and the nuclear confrontation with Iran.

It'll undoubtedly be controversial. But it will also, he expects, be humbling. The power of counterfactual thinking is that forces us to step outside of our comfort zones. When we think about historical events, we have 20/20 hindsight – so we forget how confusing and uncertain they were at the time. In 1943, nobody really knew how strong Germany was, or what Stalin was thinking. In modern conflicts, we often have a similarly false sense of surety – too much confidence in our ability to predict the outcome of major events.

When we play with sims, they knock us off our pedestals – because crazy things usually happen we don't predict. Yet the chaos is useful, because we can run the same situation again and again, changing one little thing each time, until we've war-gamed it deeply and understand it better than ever.

The United States used to be champions at this sort of strategic thinking, Ferguson notes, until Iraq came along. Much of America's failures in Iraq have been due to the overly rosy predictions of administration heads. They didn't have the healthy respect for chaos that was the original animating genius of conservatism – the thinkers like Edmund Burke, who distrusted aggressive tinkering with economies, states or cultures, because they shuddered to think of what genies might be unleashed.

Is it possible that when today's teenagers enter the workforce – and become tomorrow's historians, politicians and Pentagon war fighters – that they'll have reclaimed the ability to think counterfactually? Will all those years of gaming have trained them to imagine the many different ways a crisis can evolve?

Ferguson thinks so. "Serious games are the next big platform," he says. Which might be the biggest counterfactual of all.

Comment on this story.

Clive Thompson is a contributing writer for The New York Times Magazine and a regular contributor to Wired and New York magazines. Look for more of Clive's observations on his blog, collision detection.

Aesthletics: Game Designers Should Create More New Sports

What Type of Game Cheater Are You?

You Grew Up Playing Shoot'em-Up Games. Why Can't Your Kids?

Playing the Master Race

Columns: Games Without Frontiers