James T. Kloppenberg is Charles Warren Professor of American History at Harvard. His recent books include “Reading Obama: Dreams, Hope, and the American Political Tradition” and “Toward Democracy: The Struggle for Self-Rule in European and American Thought.”

The United States faces a national emergency, and it has nothing to do with immigration. It is a crisis of democracy. Self-government requires a willingness to accept disagreement and respect the opposition. But for decades Americans and their political leaders have been sliding in the opposite direction, threatening to send our democracy into permanent stalemate or, worse, civil war.

In his riveting new book, “If We Can Keep It: How the Republic Collapsed and How It Might Be Saved,” Michael Tomasky traces the history of conflict in American democracy and shows why self-rule is at risk today. Deep divisions, of course, are as old as the nation itself. For the most part, except for the shattering clash over slavery, Americans have sought to bargain their way toward political settlements. Tomasky shows that throughout American history — until now — our political parties were composed of unstable coalitions that helped facilitate dealmaking to resolve national conflicts. In the past, party members at times voted with the opposition to produce results. But since the 1990s, the Republican Party has marched in lockstep in support of its platform and in opposition to any deviations from it. As a result, partisanship has intensified and the democratic process of compromise has suffered.

Over time, the Republicans and Democrats evolved into conservative and liberal parties, but they are now, in Tomasky’s words, “totally different creatures.” The Republican Party has become “the conservative movement,” while the Democratic Party is “a different kind of vehicle,” a patchwork of diverse groups “too disparate to add up to a movement.” Even if small openings have appeared — a dozen Republican senators breaking ranks to vote against President Trump’s emergency declaration over funding for a border wall, for instance — real compromise between the parties still seems less likely than ever.

It wasn’t always so. At the Constitutional Convention, small states insisted on equal power with large states. That explains why every state has two U.S. senators, while House seats are allocated according to population. Southern states, notably South Carolina and Georgia, threatened to bolt from the convention if abolishing slavery even came up for debate. So, in an awful bargain, slavery survived. Disagreements could be a matter of life and death, as the duel between Alexander Hamilton and Aaron Burr illustrated. But reconciliation was preferable and, Tomasky shows, possible. In his inaugural address after the hotly contested election of 1800, which lay behind Burr’s hatred of Hamilton, Thomas Jefferson declared, “We are all Republicans, we are all Federalists,” and he meant it. Beneath their squabbles, Americans shared common ground.

As the 19th century wore on, the parties struck bargains again. But Tomasky makes clear that compromises were possible because divisions within the parties disguised a widening divide on slavery until the Civil War wrenched the nation apart. Abraham Lincoln tried valiantly in his second inaugural address to “bind up the nation’s wounds” by observing that the North shared guilt for the nation’s original sin of slavery. But his assassination reopened those wounds.

Tomasky aims his engaging popular history at “average concerned citizens” rather than pundits or scholars. It is a delight to read. A responsible, accurate history (with the single exception of locating Woodrow Wilson’s birthplace in Georgia instead of Virginia), it is informed by recent historical scholarship but not weighed down by it. Tomasky also draws heavily on the best recent analyses of our current condition, including E.J. Dionne’s “How the Right Went Wrong” and Greg Sargent’s “An Uncivil War.”

Tomasky shows that into the 20th century the parties were still able to overcome their differences, in part because of their internal divisions. Anger over the plight of farmers and industrial workers simmered until both parties adopted progressive reform measures, under Republican President Theodore Roosevelt and Democratic President Wilson. President Franklin Roosevelt was later forced to accede to Southern Democrats’ demands that the signature achievements of the New Deal exclude agricultural and domestic workers, i.e., most African Americans. The New Deal survived thanks to support from both sides of the aisle because both parties were ideologically incoherent coalitions. Moderate Republicans and Southern Democrats, although uneasy, agreed to let the programs stand. In 1954 Republican President Dwight Eisenhower wrote to his brother Edgar that “should any party attempt to abolish Social Security, unemployment insurance, and eliminate labor laws and farm programs, you would not hear of that party again.” Only a “tiny splinter group” consisting mostly of “Texas oil millionaires” disagreed. But “their number is negligible,” Ike concluded, “and they are stupid.” Maybe so, but their influence has grown steadily ever since.

While compromise was more frequent before our current era, it’s important not to romanticize its prevalence in the first 150 conflict-filled years of U.S. history. However, the challenges of the Depression and World War II did, indeed, bring Americans together. Tomasky contends that relative to what came before and after, the years from FDR’s election in 1932 to Ronald Reagan’s in 1980 can be termed “the age of consensus.” In this unique period, business and labor, rich and poor, and different ethnic and racial groups came to share a common “civic faith,” a belief that “the American way of life” makes room for everybody, even though in reality many were excluded from full participation.

As early as 1964, when Republicans put forward Barry Goldwater as their presidential nominee, right-wing activists were at work hardening the conservative line. Goldwater’s defeat failed to discourage Americans still furious over the New Deal and alarmed by the civil rights and women’s movements. In the following years, some groups and individuals invested unprecedented amounts of money in efforts to drag the Republican Party toward extreme positions on a variety of issues, from the government’s role in the economy to abortion, affirmative action, school prayer, gay rights and immigration. The result has been increasingly rigid partisanship, an unwillingness to compromise that makes it impossible for our democracy to function. This is the national emergency we face.

What is to be done? In the spirit of Wilson at the end of the war to end wars, Tomasky offers his own Fourteen Points. His political fixes: to end gerrymandering, Senate filibusters and the electoral college; increase the size of the House; shift from our unusual system of winner-take-all elections to the proportional representation of candidates from different parties within state delegations to Congress; and implement ranked-choice voting, which encourages moderation because in such systems all candidates have an incentive to be voters’ second choice, even if they will not be the first choice. All of these are sensible ideas, but as Tomasky concedes, they are highly unlikely because all these steps would threaten the far-right fringe that controls the Republican Party. His cultural fixes: foreign-exchange programs to give high schoolers, college students and young employees of big corporations a chance to encounter the conditions and views of communities unlike their own; engendering social responsibility in corporate leaders now interested only in short-term profits; and expanding the study of history and civics to awaken students to their civic duties.

Finally, Tomasky implores the left not to further fracture our already fractured politics. At a moment when many Democrats are encouraging the party to go low in its electoral strategy and to advance truly ambitious, budget-busting programs such as Medicare for all, tuition-free college and a Green New Deal, Tomasky makes an impassioned — and persuasive — plea for progressives to aim instead for incremental progress that will attract middle-of-the-road voters. When Alexis de Tocqueville visited the United States in 1831, he was impressed as much by Americans’ willingness to help one another and by their civic engagement as he was by their industriousness. He thought these qualities reinforced each other. What we need now, Tomasky shows, is to redirect our passion toward rebuilding our democracy, renouncing hyper-partisanship, and cultivating commitments to reasoned debate, respectful disagreement and an unending search for responsible compromise.

If We Can Keep It

How the Republic Collapsed and How It Might Be Saved

By Michael Tomasky.

273 pp. $27.95