Colombia's government and the country's biggest rebel group have reached an historic peace deal, ending half a century of hostilities in one of the world's longest-running and bloodiest armed conflicts, which once took the resource-rich country to the brink of collapse.
President Juan Manuel Santos hailed the agreement with the Revolutionary Armed Forces of Colombia (FARC) as an opportunity to turn the page on decades of political violence that has claimed more than 220,000 lives and driven more than five million people from their homes.
Some 400 people gathered in the capital Bogota to watch the agreement being announced on a giant screen by negotiators in Havana, where four years of talks came to an end.
"We've won the most beautiful of all battles: the peace of Colombia," the chief FARC negotiator, Ivan Marquez, said at the announcement.
President Juan Manuel Santos, 65, who was re-elected in 2014 on the promise of a peace deal, said: "Today I can say - from the bottom of my heart - that I have fulfilled the mandate that you gave me."
What has the long-running conflict been about?
The FARC took up arms in 1964 to fight against deep economic and social inequalities. Funded by the cocaine trade and kidnappings for ransom, the group swelled to as many as 17,000 fighters at the end of the 1990s, controlling large swathes of the country.
According to polls, the group are not popular with most Colombians, who label them "narco-terrorists" for their heavy involvement in the country's cocaine trade.
The rebel army was forced to the negotiating table after a decade of heavy battlefield losses that saw a succession of top rebel commanders killed by the U.S.-backed military and the its ranks thinned by half to the current 7,000 troops.
What agreement has now been reached?
Under the terms of the historic agreement reached on Wednesday evening, the FARC will pay down arms and reintegrate into civilian life.
The deal commits Colombia's government to carrying out aggressive land reform, overhauling its anti-narcotics strategy and greatly expanding the state's presence in long-neglected areas of the country.
The FARC will have non-voting representation in Congress until 2018 and can participate in elections.
What has been the reaction to the agreement?
The news sparked wild celebrations in bars and parks across Bogota.
"I'm so happy. It was time to end the war," said Margarita Nieto, a 28-year-old accountant. "I know what is coming will be hard, but together we can cope."
Congratulations also poured in from the United Nations and other countries.
U.S. President Barack Obama said in a statement that the announcement was "a critical juncture in what will be a long process to fully implement a just and lasting peace agreement that can advance security and prosperity for the Colombian people."
However the deal was opposed by two former Colombian presidents, including popular right-wing hardliner Alvaro Uribe.
So is Colombia finally at peace now?
Not yet. The agreement will now go to a referendum on October 2.
While polls say Colombians will likely endorse a deal in a simple yes or no vote, the opposition is likely to try to convert the vote into a referendum on Santos, whose approval rating plummeted to 21 percent in May.
Low voter turnout is also a concern because a minimum of 13% of the electorate, or about 4.4 million voters, must vote in favour for the deal to be ratified.
An agreement with the FARC does not guarantee an end to political violence, either.
Talks between the smaller, leftist National Liberation Army and the government have stalled.
Criminal gangs born out of right-wing paramilitary groups that were active during the worst periods of the conflict have since taken over some key drug trafficking routes.
However violence is at its lowest level in decades.