It’s 1812, and a big, bloody war is banging on America’s door. As the British besiege lands to the north, east, and south of their former territory, thousands of African American slaves have a choice: fight or flight. What will they choose to do, and why?

Gene Allen Smith takes the motivations of slaves and freemen to heart in a riveting new history, The Slaves’ Gamble: Choosing Sides in the War of 1812. “My question was a simple one: why did some free blacks and slaves side with the United States during the War of 1812, and why did others join the British, the Spanish, the Native American tribes, or the maroon communities?” Smith writes.

Smith, a professor at Texas Christian University, was first asked by an undergraduate why black slaves were among Gen. Andrew Jackson’s ranks at the battle of New Orleans. (The War of 1812 holds particular interest for Smith, who grew up in an Alabama neighborhood through which Jackson’s troops tramped.) Over the course of 15 years, he unearthed rich and complicated reasons why, as Americans fought to maintain their hard-won self-determination in the “second war of independence,” thousands of slaves were enticed to battle or flee. Simply stated, “African Americans had hoped collectively that this war could provide the opportunity to continue that march for self-determination and freedom,” Smith says.

Both the British, stretched thin by concurrent participation in the Napoleonic Wars, and the fledgling American army needed soldiers to fill their ranks. Opportunities to enlist came on multiple fronts: along the Canadian border at the Great Lakes; at Baltimore and Washington, D.C., where the British torched the White House and most of the capital city; and in the Gulf Coast, culminating in Jackson’s heroic win at New Orleans. As they grappled for additional manpower, Spanish, Native American, Creole and pirate soldiers joined the fight but none had as much to gain as the slaves, who were promised freedom by both sides.

Peter Denison, Prince Witten, Charles Ball, Ned Simmons, Jordan B. Noble, and George Roberts are some of the African American men who capitalized on this chance to choose. Whether they succeeded or failed in their quests for freedom, their efforts, as remembered by Smith, are extremely moving. “You feel their pain and their agony, and you experience their joy. It’s almost like they become a part of your family,” says Smith. Witten joined the Spanish in Florida, lived a life of honor and acclaim, and emigrated to Cuba when the Americans conquered the territory. Simmons valorously represented the British  at Cumberland Island, Georgia, but returned to bondage due to a technicality in the Treaty of Ghent: all American property not removed to British soil reverted to its original owner. “Poor old Ned Simmons had his uniform stripped, his weapons taken away,” Smith says. “He doesn’t gain freedom until 1863, in the American Civil War, when he crosses into Union-controlled Florida and is granted his freedom as a centenarian.”Slaves' Gamble

In general, the slaves’ interests were best served under the Union Jack. Those who didn’t want to fight were granted asylum, and 5,000 were relocated to British colonies in Belize, Bermuda, Canada, or Trinidad. American soldiers promised freedom by Jackson, however, were lied to. After the war they were stripped of their weapons and reenslaved. Ironically, the slaves’ admirable service set back their march to freedom, as Southern slaveowners employed even harsher discipline to keep these experienced warriors from rebelling. “Black unity that had been valued during the war thereafter became viewed as a threat. ... No longer would free blacks be embraced as civic contributors and continue their march toward equality. Instead, they would find themselves wedged between slavery and freedom, between race discrimination and egalitarianism,” Smith writes. Freemen fared little better. Their promised rewards came slowly, if at all.

“Writing on the War of 1812, I’ve always used the English as the villain, and kind of slapped them around,” says Smith. “As I worked on this project, the more I realized that, for African Americans, the British and the Spanish are the heroes.”

Megan Labrise is a freelance writer and columnist based in New York. Follow her on Twitter @mlabrise.