Nicaragua has signed the Paris climate agreement, meaning that the US and Syria are the only two countries not to be giving the accord their support.
The deal unites the world's nations in tackling climate change.
Nicaragua refused to sign it last year, arguing that it did not go far enough to tackle the problem.
In June President Donald Trump said the US would withdraw from the deal, but the rules of the agreement state that this cannot be done until 2020.
The president said it was part of his "solemn duty to protect America" and he would seek a new deal that would not disadvantage US businesses.
Scientists point out that work to implement the Paris accord must be stepped up if it is to have any chance of success.
The agreement commits the US and 187 other countries to keeping rising global temperatures "well below" 2C above pre-industrial levels and "endeavour to limit" them even more, to 1.5C.
Nicaraguan President Daniel Ortega indicated last week that he would sign the accord.
"It is time for Nicaragua to sign the Paris Agreement," Mr Ortega said on the official July 19 website.
"Scientists from more developed countries, scientists working at Nasa, European scientists, everyone agrees that we must stop the process that is leading to the destruction of the planet," he said.
Mr Ortega's government had previously argued that the accord did not put sufficient onus on wealthy countries to tackle climate change and was not ambitious enough in its objectives.
Nicaragua has no oil and vigorously pursues green energy policies – more than 50% of its electricity is produced by geothermic, wind, solar, biomass and wave power. It is a country that is believed to be especially at risk from climate change.
The World Bank described the central American country as "a renewable energy paradise" in 2013.
President Trump has argued that the Paris agreement would hobble, disadvantage and impoverish the US, to the benefit of other nations.
He claimed in June that the accord would cost the US 6.5 million jobs and $3tn (£2.2tn) in lost GDP – while rival economies like China and India were treated more favourably.
However, the US more recently has hinted that it may shift its position on withdrawing from the deal.
Historically, the US, Europe, and China account for almost half of the world's carbon emissions.
Syria is thought not to have signed the deal because it has been preoccupied by its civil war.Let's