Catalonia's regional parliament, which is dominated by parties that want the region to break away from Spain, approved Wednesday a 2017 budget that includes funding for an independence referendum.
The move poses a serious challenge to Spain's central government in Madrid, which argues an independence referendum would be illegal and against the constitution -- a stance supported by the judiciary.
The spending plan was approved with 64 votes in favour, 62 against and seven abstentions.
The wealthy region in northwestern Spain, which has its own distinct language in addition to Spanish, is governed by a coalition of separatist parties called "Junts pel Si" or "Together for Yes".
An amendment to the budget calling for it to "guarantee the necessary resources to organise and stage" a referendum "on the political future of Catalonia was tabled by the coalition' minority partner, the tiny anti-capitalist CUP.
The Catalan government has vowed to hold an independence referendum by September -- with or without the approval of the central government.
Spain's Constitutional Court convicted earlier this month former Catalan president Artur Mas, who governed the region from 2010 until 2016, of civil disobedience and banned him from holding office for two years for organising an illegal independence referendum in 2014.
The former spokesman for the Catalan government, Francesc Homs, was on Wednesday banned from holding office for a year and a half and fined 30,000 euros ($32,000) for his role in staging the 2014 referendum.