Spain's public deficit to August, without counting local government debt, stood at 4.8 percent of GDP, or 49.212 billion euros, a government official announced on Tuesday.
This amount includes spending by the central government, Spain's autonomous regions and the social security system.
Spain is trying to meet its goal to close the year with a budget deficit of 6.5 percent of GDP, as agreed with Brussels by the government.
The figure for the first eight months of the year would rise to as much as 5.07 percent of GDP were the bail-out money granted by a European fund to shore up Spain's banks included in the calculation.
Marta Fernández-Currás, the secretary of state for budgets and spending, explained that the deficit figures are expected to improve once amounts from local governments are included, which they forecast will show an improvement from the last budget surplus figures of 0.19 percent.
Up until August, the central government's non-financial operations registered a deficit of 39.188 billion euros, or 3.82 percent of GDP. The combined deficit figure for the regions came in at 8.135 billion, or 0.79 percent of GDP - similar to the figures seen in July.
Three regions - Asturias, the Balearic Islands and La Rioja - showed surpluses while the Canaries closed the period with a near balanced budget.