Oil has soared above $54 a barrel to its highest level in nearly a year and a half.

U.S. crude futures jumped more than 5% on Monday after Russia and a bunch of other big producers agreed over the weekend to join OPEC members in cutting their output next month.

"There is optimism in the market that finally the oil glut will soon dissipate," said Ali Hamoudi, CEO of Adaa Financial Services in Dubai.

The group of non-OPEC nations -- which includes Mexico, Kazakhstan and Oman -- will aim to reduce their production by 558,000 barrels a day, according to a statement. That follows OPEC's deal last month to cut its overall production by 1.2 million barrels a day.

Related: Trump backer says it's 'foolish to double U.S. oil output

The OPEC agreement capped months of fraught negotiations that pitted the cartel's de-facto leader Saudi Arabia against its regional rival Iran.

Oil prices got a further lift Monday from reports over the weekend suggesting Saudi Arabia is willing to slash its output even further than the amount it had initially promised.

"Saudi Arabia was the main driver for this deal to come through," Hamoudi said.

The idea is that a production cut will help boost crude prices, which have now more than doubled from a low of near $26 per barrel in February.

Related: Oil bust winner: Saudi Arabia's tech scene

OPEC members had said they would only cut production if the non-OPEC producers agreed to cut as well.

But even though this weekend's deal includes several big exporters, other major producers -- such as the U.S. and Canada -- are not involved.

"The question which troubles some investors is whether the higher oil price will give the U.S.'s shale oil production a new lease of life," said Naeem Aslam, chief analyst at Think Markets in London.

And markets will be watching closely to see whether OPEC and non-OPEC states comply with the agreement.