As marchers took to the streets of Boston in late April to demand justice for Freddie Gray, some of them began to sing: “We shall overcome, we shall overcome, we shall overcome some day ...”

It wasn’t a surprising choice. “We Shall Overcome” is a staple for civil-rights protests—and for that matter, for any kind of social-justice movement. The Library of Congress calls it “the most powerful song of the 20th century.” So it was a surprise to learn that not only is the identity of the person who made it into that anthem known, but he died only on May 2.

His name was Guy Carawan, and he was 87 years old. The story of the song and how Carawan helped make it ubiquitous is full of surprises, and it’s a wonderful demonstration of the folk tradition at work, accreting bits and pieces over the years until it became today’s widely known version. It’s also, appropriately enough for a civil-rights anthem, the story of a song that draws heavily on both African American and European American traditions, just like all the best American music. Like so many folk songs, it feels as though it’s existed forever; asking who wrote it seems ridiculous. Hasn’t it always been there?

Actually, although the song is old, its history can be fairly carefully traced. The first few bars seem to derive from a hymn first published in 1792, called “O Sanctissima,” also published as “Sicilian Mariners’ Hymn.” As The New York Times notes in its Carawan obituary, Beethoven wrote a setting of the hymn, and the resemblance is unmistakable for even the least trained ear, though it diverges after the first few lines. The Times says that a version published in the United States in 1794 was already recognizably the melody known as “We Shall Overcome.”

The basic frame of the words seems to have come from “I’ll Overcome Some Day,” a hymn written by the Reverend Charles Albert Tindley, a famed black preacher in Philadelphia, and published in 1901. Tindley’s tune bears little in common with “Sicilian Mariners,” as you can see here. His words are also far more elaborate, and focus more on salvation of the individual by God, rather than the power of collective action. The lyrical similarity comes with a refrain on each verse, in the familiar AABA structure, that presages “We Shall Overcome.”

So when the did the song cross over from the sacred to the secular? The first appearance of the modern version of “We Will Overcome” comes from 1945. Workers in the Food, Tobacco, Agricultural & Allied Workers Union in Charleston, South Carolina, went on strike at an American Tobacco Company cigar factory. The workers were largely, though not exclusively, black women. They reportedly ended each day’s picket with a verion of the song. Zilphia Horton, a labor organizer and musician, heard the song there, and Pete Seeger learned it from her. (Seeger is credited with changing the opening line from “We will overcome” to “we shall overcome,” though he wasn’t so sure.) Over the ensuing decade, the song was published and recorded several times.

Carawan, meanwhile, had served in the Navy in the U.S. during World War II and then studied at UCLA, taking a master’s in sociology. Able to play the guitar, banjo, and hammer dulcimer, he moved to New York City and joined the folk revival in Greenwich Village. In 1953, he traveled through the South with Frank Hamilton (who was not yet a member of the Weavers) and Jack Elliott (who was not yet Ramblin’). At Seeger’s suggestion, they stopped at the Highlander Folk School in Tennessee, an organizing school founded by Zilphia Horton and her husband Myles. Carawan learned “We Shall Overcome” there. In 1959, when Zilphia Horton died, he became Highlander’s music director.

In 1960, at the founding convention of the Student Nonviolent Coordinating Committee, in Raleigh, North Carolina, Carawan was asked to lead delegates in a song, and he chose “We Shall Overcome.” Carawan began accompanying himself on guitar, and soon the room was joining him. As he told NPR in 2013, it was an immediate hit:

That song caught on that weekend. And then at a certain point, those young singers, who knew a lot of a cappella styles, they said, “Lay that guitar down, boy. We can do this song better.” And they put that sort of triplet to it and sang it a cappella with all those harmonies. It had a way of rendering it a style that some very powerful young singers got behind and spread.

It’s not hard to see, or hear, why. The song is easy to sing, with a musical arc that seems to enact a rise to victory and then a relieved denouement. Hymns are, of course, made to be easy to sing for large groups of untrained singers. The melody of “We Shall Overcome”—unlike, say, “The Star-Spangled Banner”—spans a tiny range, barely more than an octave, from middle C up to a D. It’s easy to accompany, but instruments aren’t necessary. The lyrics are easy, too—the AABA structure, like a blues song, is straightforward, and it leaves long pauses for a leader to queue a group. Yet the combined effect of these simple elements is, as in all the best folk music, enough to send chills up the spine.

SNCC would go on to play a crucial role in that phase of the civil-rights movement, and soon the song was everywhere. In February 1965, speaking at Temple Israel in Hollywood, Martin Luther King cited it (while also quoting The Atlantic’s first editor, James Russell Lowell):

Yes, we were singing about it just a few minutes ago: "We shall overcome; we shall overcome, deep in my heart I do believe we shall overcome."

And I believe it because somehow the arc of the moral universe is long but it bends toward justice. We shall overcome because Carlyle is right: “No lie can live forever.” We shall overcome because William Cullen Bryant is right: “Truth crushed to earth will rise again.” We shall overcome because James Russell Lowell is right: “Truth forever on the scaffold, wrong forever on the throne. Yet, that scaffold sways the future and behind the dim unknown standeth God within the shadow, keeping watch above his own.”

King also mentioned the song in his final sermon in Memphis.

And when Lyndon Johnson called on Congress to pass the Voting Rights Act the following month, in March 1965, he too alluded to the song:

But even if we pass this bill, the battle will not be over. What happened in Selma is part of a far larger movement which reaches into every section and State of America. It is the effort of American Negroes to secure for themselves the full blessings of American life.

Their cause must be our cause too. Because it is not just Negroes, but really it is all of us, who must overcome the crippling legacy of bigotry and injustice.

And we shall overcome.

After more than 150 years of near obscurity, the song hasn’t left the popular consciousness since. It was performed at the chaotic 1968 Democratic Convention and at countless grammar-school performances. It’s been adopted by Northern Irish Catholics protesting British rule and by fans of the second-tier British soccer team Middlesbrough F.C. It has been performed as a free-jazz dirge by Charlie Haden and as symphonic kitsch by Diana Ross, as soft rock by Roger Waters and, delightfully, as fast reggae by the Maytals.

Like all totems, “We Shall Overcome” has reached the stature that sometimes earns it derision. As marchers in Boston sang it, Kirsten West Savali dismissed it as a symbol of the past, complaining on The Root: “We’re expected to be angels when we’re faced with demons. We’re expected to hold hands, sing, ‘We Shall Overcome,’ and wait patiently for the wheels of justice to turn and for freedom to ring.” But for many people, the song remains an uplifting and unifying presence. When President Obama and other dignitaries went to Selma, Alabama, in March 2015 to mark the 50th anniversary of Bloody Sunday, he, too, cited the song.

As it happens, Carawan's contribution with the song didn’t end with music. In the 1960s, Carawan, Seeger, Hamilton, and Horton’s estate obtained a copyright for the song—mostly, Seeger said, to prevent anyone else from doing it. The proceeds from the song go to a fund black cultural expression in the South, through Highland. As for Carawan, he stayed at Highlander until retiring in the late 1980s. He died at home, where he lived next door to the center. His legacy in introducing “We Shall Overcome” to the American people is as timeless as the song feels.