On May 5, 1857, eight men sat down to dinner at Boston’s Parker House hotel. They had gathered to plan a magazine, but by the time they stood up five hours later, they had laid the intellectual groundwork for a second American revolution.

These men were among the leading literary lights of their day, but they had more in mind that night than literary pursuits. The magazine they envisioned would, its prospectus later promised, “honestly endeavor to be the exponent of what its conductors believe to be the American idea.”

That prospectus bore the unmistakable stamp of The Atlantic’s founding editor, James Russell Lowell, but “the American idea” had been popularized by Theodore Parker, the radical preacher and abolitionist. The American idea, Parker declared in an 1850 speech, comprised three elements: that all people are created equal, that all possess unalienable rights, and that all should have the opportunity to develop and enjoy those rights. Securing them required “a government of all the people, by all the people, for all the people,” Parker said.

Ralph Waldo Emerson, another Atlantic founder, put the matter more concisely. There was, he observed, a single phrase, offered by the little republicans of the schoolyard, that summed the whole thing up: “I’m as good as you be.”

As a vision, it was bold and improbable—but the magazine these men launched that November, 160 years ago, helped spur the nation to redefine itself around the pursuit of the American idea. And as the United States grew and prospered, other peoples around the globe were attracted to its success, and the idea that produced it.

Now, though, the idea they articulated is in doubt. America no longer serves as a model for the world as it once did; its influence is receding. At home, critics on the left reject the notion that the U.S. has a special role to play; on the right, nationalists push to define American identity around culture, not principles. Is the American idea obsolete?

From the first, the idea provoked skepticism. It was radical to claim that a nation as new as America could have its own idea to give the world, it was destabilizing to discard rank and station and allow people to define their own destinies, and it bordered on absurd to believe that a nation so sprawling and heterogeneous could be governed as a democratic republic. By 1857, the experiment’s failure seemed imminent.

Across Europe, the 19th century had dawned as a democratic age, but darkened as it progressed. The revolutions of 1848 failed. Prussia busily cemented its dominance over the German states. In 1852, France’s Second Republic gave way to its Second Empire. Spain’s Progressive Biennium ended in 1856 as it began, with a coup d’état. Democracy was in full retreat. Even where it endured, the right to vote or hold office was generally restricted to a small, propertied elite.

On the surface, things appeared different in Boston, where The Atlantic’s eight founders—Emerson, Lowell, Moses Dresser Phillips, Henry Wadsworth Longfellow, John Lothrop Motley, James Elliot Cabot, Francis H. Underwood, and Oliver Wendell Holmes Sr.—dined in May 1857. Almost all adult males in Massachusetts, black and white alike, could vote, and almost all did. Almost all were literate. And they stood equal before the law. The previous Friday, the state had ratified a new constitutional amendment stripping out the last significant property qualifications for running for state Senate.

But even in Boston, democracy was embattled. The state’s government was in the grip of the nativist Know-Nothings, who resented recent waves of immigrants. That same Friday, voters had ratified an amendment imposing a literacy test for voting, a mostly symbolic effort at exclusion. But slavery, the diners believed, posed an even greater threat to democracy. Most of them had been radicalized three years before by the Anthony Burns case, when federal troops marched into their commonwealth to return Burns, an escaped slave then living and working in Boston, to bondage in Virginia—inspiring protests and lethal violence on his behalf. To the west, Kansas was bloodied by fighting between pro- and antislavery elements; to the south, politicians had begun defending slavery not as a necessary evil but as a positive ideal.

The fight against slavery had become a struggle for the American idea; the two could not coexist. In 1860, Abraham Lincoln’s election led the South to conclude that it had lost the argument. The seceding states left Congress with a Republican majority, able to translate the principles of equality, rights, and opportunity into practical action: homesteads for all who sought them; land-grant colleges to spread the fruits of education; tariffs to protect fledgling industries; and a transcontinental railroad to promote commerce and communication. Here was the American idea made manifest.

But the Civil War tested whether a nation built around that idea could “long endure,” as Lincoln told his audience at Gettysburg in 1863. His address aimed to rally support for the war by framing it as a struggle for equality, rights, and opportunity. He echoed Parker’s speech defining the American idea in order to make clear to his listeners that it fell to them to determine whether “government of the people, by the people, for the people, shall not perish from the earth.”

When the Union prevailed, it enshrined this vision in the Constitution with a series of amendments banning slavery, extending equal protection of the law, and safeguarding the right to vote for Americans of all races. In the ensuing decades, the rapid growth of the United States attracted further waves of immigrants and transformed the country into a global power. Some countries and peoples attempted to replicate American success by embracing American principles. Others recoiled and embraced alternatives—monarchy, empire, communism, and fascism among them.

The United States and its allies triumphed in two world wars and in a third that was undeclared—the first, Woodrow Wilson said, waged so that the world might “be made safe for democracy”; the second, Franklin D. Roosevelt explained, “to meet the threat to our democratic faith”; and the third, Ronald Reagan declared, to settle “the question of freedom for all mankind.” Each victory brought with it a fresh surge of democratization around the world. And each surge ebbed, in part because the pursuit of equality, rights, and opportunity guarantees ongoing contention while the alternatives offer the illusion of stability.

The American story isn’t simply an arc of history bending toward justice; it’s far messier. Americans have never agreed on when to prioritize the needs of individuals and when their collective project should come first. If this tension wasn’t itself unifying, it nonetheless helped stake out the terrain over which productive national debate could be waged.

So where does the American idea stand today? To some extent, it is a victim of its own success: Its spread to other nations has left America less distinctive than it once was. But the country has also failed to live up to its own ideals. In 1857, the United States was remarkable for its high levels of democratic participation and social equality. Recent reports rank the U.S. 28th out of 35 developed countries in the percentage of adults who vote in national elections, and 32nd in income equality. Its rates of intergenerational economic mobility are among the lowest in the developed world.

On opportunity, too, the United States now falls short. In its rate of new-business formation and in the percentage of jobs new businesses account for, it ranks in the lower half of nations tracked by the Organization for Economic Cooperation and Development. Today, Americans describe China as Europeans once described the United States—as an uncouth land of opportunity and rising economic might.

It is no surprise that younger Americans have lost faith in a system that no longer seems to deliver on its promise—and yet, the degree of their disillusionment is stunning. Nearly three-quarters of Americans born before the Second World War assign the highest value—10 out of 10—to living in a democracy; less than a third of those born since 1980 do the same. A quarter of the latter group say it’s unimportant to choose leaders in free elections; just shy of a third think civil rights are needed to protect people’s liberties. Americans are not alone; much of western Europe is similarly disillusioned.

Around the globe, those who dislike American ideas about democracy now outnumber those who favor them. Vladimir Putin’s Russia offers a bellicose, authoritarian alternative. China whispers seductively to rulers of developing nations that they, too, can keep a tight grip on power while enjoying the spoils of economic growth.

All of this has left many Americans feeling disoriented, their faith that their nation has something distinctive to offer the world shaken. On the left, many have gravitated toward a strange sort of universalism, focusing on America’s flaws while admiring other nations’ virtues. They decry nationalism and covet open borders, imagining a world in which ideas can prevail without nations to champion them.

Even as the left is made queasy by the notion that an idea can be both good and distinctively American, many on the right now doubt that America is a land defined by a distinctive idea at all. President Donald Trump’s rhetoric is curiously devoid of references to a common civic creed. He promotes instead a more generic nationalism—one defined, like any nation’s, by culture and borders and narrow interests and enemies.

Both of these visions are corrosive, although not equally. America is an ethnically, geographically, and economically varied land. What helped reunite the states a century and a half ago was a nationalism grounded in a shared set of ideals, ideals that served as a source of national pride and future promise. But nationalism, the greatest force for social cohesion the world has yet discovered, can be wielded to varied ends. Trump embraces an arid nationalism defined by blood and soil, by culture and tradition. It accounts for his moral blindness after the protests in Charlottesville, Virginia—his inability to condemn the “very fine people” who rallied with the Ku Klux Klan and neo-Nazis against “changing culture.” That sort of cultural nationalism can easily shade into something uglier, and glues together only a fraction of Americans.

With democracy in retreat abroad, its contradictions and shortcomings exposed at home, and its appeal declining with each successive generation, it’s 1857 all over again. But if the challenges are the same, the solution may also be familiar. Vitriol and divisiveness are commonly blamed for the problems of contemporary politics. But Americans aren’t fighting too hard; they’re engaged in the wrong fights. The universalism of the left and cultural nationalism of the right are battering America’s sense of common national purpose. Under attack on both flanks, and weakened by its failure to deliver exceptional results, the nation’s shared identity is crumbling.

Americans have been most successful when fighting over how to draw closer to the promise of their democracy; how to fulfill their threefold commitment to equality, rights, and opportunity; and how to distribute the resulting prosperity. They have been held together by the conviction that the United States had a unique mission, even as they debated how to pursue it.

The greatest danger facing American democracy is complacence. The democratic experiment is fragile, and its continued survival improbable. Salvaging it will require enlarging opportunity, restoring rights, and pursuing equality, and thereby renewing faith in the system that delivers them. This, really, is the American idea: that prosperity and justice do not exist in tension, but flow from each other. Achieving that ideal will require fighting as if the fate of democracy itself rests upon the struggle—because it does.