PARIS — A global climate pact lauded as a "historic turning point" was adopted Saturday by world leaders after two weeks of intensive talks.

"This is a tremendous victory for all of our citizens," U.S. Secretary of State John Kerry said at the summit after the landmark agreement passed. "We have taken a critical step forward."

The first-ever international accord, agreed to by nearly 200 nations, requires all countries to take steps to reduce greenhouse gas emissions. Leaders burst into cheers after it was passed, many hugging each other with tears in their eyes.

U.N. Secretary General Ban Ki-moon, right, watches French President Francois Hollande hugging United Nations climate chief Christiana Figueres after the final conference of the COP21 in Le Bourget, France, on Dec. 12, 2015. Francois Mori / AP

The "Paris agreement" also aims to keep the rise in global temperatures "well below" 2 degrees Celsius (3.6 degrees Fahrenheit) from pre-industrial times to the end of this century and "endeavor to limit" them even further, to 1.5 degrees Celsius.

To achieve that goal, the world has to stop emitting greenhouse gases altogether in the next half-century, according to scientists. And they must commit to limiting the amount of greenhouse gas pollution from human activity to the same levels that trees, soil and oceans are naturally able to absorb before then.

While the pact calls for all countries to reduce and eventually eliminate greenhouse gas pollution, it imposes no sanctions on countries who don't.

"Years from now, our grandchildren will reflect on humanity's moral courage to solve the climate crisis. And they will look to Dec. 12, 2015, as the day when the community of nations finally made the decision to act," said former Vice President Al Gore, a champion of environmental activism. Gore was in Paris along with leaders from 195 countries for the pact.

The deal, which will take effect in 2020, is the first time all countries are being urged to join the fight against climate change. Previously, U.N. talks had only called on wealthy nations to reduce their emissions.

In a televised statement Saturday afternoon, President Barack Obama praised world leaders for working together to agree on a deal that "offers the best chance to save the one planet we have."

But Obama also conceded that "no agreement is perfect, including this one."

The lack of a plan that could please all parties was evident as environmental and human rights groups broke into protests around Paris. They called attention to populations threatened by man-made global warming and urged an end to the use of oil, gas and coal.

Related: Final Text of Climate Accord Expected Early Saturday

Among those slamming the deal was Democratic presidential candidate Bernie Sanders, who said in a statement that the accord “goes nowhere near far enough” to commit nations to lower planet-warming carbon emissions.

More from MSNBC: Bernie Sanders Wants More From Paris Climate Accord

"The planet is in crisis. We need bold action in the very near future and this does not provide that,” he said.

But fellow Democratic contender Hillary Clinton called the agreement an "historic step."

"The Paris agreement is testament to America's ability to lead the world in building a clean energy future where no one is left out or left behind," she said in a statement.

Before the deal was done, U.N. Secretary General Ban Ki-moon made an impassioned entreaty to world diplomats negotiating the accord.

"The whole world is watching. Billions of people are relying on your wisdom," he said. "The time has come to acknowledge that national interests are best served by acting in the international interest."

"We have to do as science dictates. We must protect the planet that sustains us. We need all our hands on deck," Ban added.

French Foreign Minister Laurent Fabius called the agreement a “historic turning point” and said the “final draft" is legally binding.

Even up until the final minutes, it wasn’t clear whether an agreement would be reached. As world leaders were examining the text, Kerry told reporters, "We think it's good, but we'll see. Little things can happen, but we think it's teed up. "

NBC News' Elizabeth Chuck reported from New York.