The House of Representatives in South Carolina has voted to take down the Confederate flag from capitol grounds after a long and fractious debate.
The state House approval, by 93-27, follows a similar move in the Senate. After a final procedural vote, the bill will go to the governor for signature.
Republican Governor Nikki Haley supports the removal of the flag.
The backlash against the emblem grew when a gunman killed nine black people at a Charleston church last month.
Dylann Roof, the 21-year-old charged with the killings, was pictured holding the flag.
The flag – used by the South in the American Civil War (1860-65) – is seen by some as an icon of slavery and racism while others say it symbolises US heritage and history.
The banner could now be removed within days.
‘Insult to injury’
The House vote was taken early on Thursday morning after 13 hours of debate.
During a heated session, dozens of amendments by Republicans aimed at slowing down passage of the bill were rejected.
Some Republicans argued the flag was part of US history that had been “hijacked” by racists.
Representative Mike Pitts said the flag was a reminder of how poor farmers had fought the Union not to support slavery but to protect their land rights.
Chris Corley proposed replacing the emblem with a white flag of surrender, saying: “Maybe that will make everybody happy.”
But fellow Republican representative Jenny Horne, a descendant of Confederate President Jefferson Davis, recalled the funeral of state Senator Clementa Pinckney, who was killed in the Charleston attack, and said there should be no stalling on the removal of the flag.
She said: “For the widow of Sen Pinckney and his two young daughters, that would be adding insult to injury and I will not be a part of it!”
Democratic Party Representative Joe Neal said: “South Carolina can remove the stain from our lives. I never thought in my lifetime I would see this.”
The Confederate flag was originally the battle emblem of the southern states in the American Civil War which tried to break away.
South Carolina was the first state to leave the union in 1860. It restored the flag in the capitol grounds more than 50 years ago in protest at the civil rights movement.