Saudi Arabia posted a budget deficit of 5.3 billion ($1.41 billion) riyals in the second quarter of 2023, the finance ministry said on Thursday, as lower oil revenue weighed.

The world's top oil exporter recorded a budget surplus of almost $30 billion in 2022, beating its own estimates, as higher oil prices boosted government revenues by 31%.

But data released on Thursday showed that the budget deficit has extended to 8.2 billion riyals year to date in 2023, raising the possibility of a tilt into a full-year deficit in 2023 after last year's surplus.

Total revenues in the second quarter stood at 314.8 billion riyals, down 15% from the prior year period, while spending was up 9% over the same period last year, at just over 320 billion riyals, the finance ministry said in its quarterly budget performance report.

The Saudi economy grew 8.7% last year as high oil prices boosted revenue and led to the kingdom's first budget surplus in almost 10 years, and the government has forecast a second, albeit narrower, surplus this year.

However, there has been a significant drop in revenue from oil exports this year as lower prices and production cuts weigh.

Oil revenues in the second quarter dropped 28% year on year, to 179.7 billion riyals and made up 57% of total revenue. In contrast, non-oil revenue was up 13% in the quarter.

The world's top oil exporter will extend a voluntary oil output cut of 1 million barrels per day for another month to include September, the state news agency SPA said, also on Thursday, to provide additional support to the oil market.

($1 = 3.7509 riyals)

(Reporting by Rachna Uppal and Nadine Awadalla; Writing by Rachna Uppal; Editing by Alex Richardson and Jonathan Oatis)