Prime minister Mariano Rajoy made the announcement after an urgent meeting with members of his cabinet.
He said the vote, planned for October 1, is illegal and an attack on Spain’s and Catalonia’s institutional order.
In a televised appearance, the conservative leader said the vote does not have the democratic protections needed to be considered a referendum and promised it would not take place.
He also branded a parliamentary showdown on Wednesday to approve the referendum’s legal framework a “political perversion” by the leaders of the Catalan government.
Earlier, Spain’s leading prosecutor said criminal suits are being lodged to prosecute Catalan officials responsible for scheduling the vote on independence.
Chief state prosecutor Jose Manuel Maza said two different lawsuits are in the works, one that seeks to punish members of Catalonia’s parliament who allowed the debate and vote on the legal framework of the referendum, and a separate one against the executive branch of the regional government, whose members officially called the referendum.
He said the officials could be charged with disobedience, abuse of power and embezzlement.
The state prosecutor’s office has also instructed officials and police forces in Catalonia - the north-eastern region whose capital is Barcelona - to investigate and stop any actions taken towards the celebration of the referendum.
Mr Rajoy said in the televised address: “There won’t be a self-determination referendum because that would be taking away from other Spaniards the right to decide their future.”
The constitutional court has previously ruled that a referendum can only be called with the approval of the central authorities.
The pro-independence coalition in power in Catalonia claims it has the democratic mandate to deliver on a promise to seek independence and that the universal right to self-determination overrules Spain’s laws.
Regional president Carles Puigdemont signed the decree for the October 1 vote late on Wednesday.
“Patriotic unities that go beyond the rights of citizens don’t have a place in today’s Europe,” Mr Puigdemont said, adding that Catalonia belongs to “the world that looks forward” by holding the referendum.
Mr Rajoy is trying to strike a delicate balance between tamping down the secessionist defiance but staying away from dramatic measures that would further inflame anti-Spanish sentiments, such as suspending Catalonia’s autonomous powers or declaring a state of emergency, which could bring the military into the mix.
His conservative government has not disclosed what other possible measures are in the pipeline, but it has vowed to trigger actions in a “proportional” way and “with serenity”.
“The constitution can be modified but through the rules and channels established, never through disobedience,” Mr Rajoy said.
Although much of the blame for the institutional crisis has been put on the pro-independence bloc in the Catalan parliament, Mr Rajoy’s government is being targeted by other political parties for letting the situation get this far.
The Catalonia region generates a fifth of Spain’s gross domestic product.
It self-governs in several important areas, such as police, health and education, but key areas such as taxes, foreign affairs and most infrastructures are in the hands of the Spanish government.
Catalan and Spanish are spoken in the region of 7.5 million people, and many Catalans feel strongly about their cultural heritage and traditions.
The pro-independence bloc has argued that full control would benefit Catalonia. The idea gained support amid the high unemployment and harsh austerity measures that came as a result of Spain’s 2008-13 financial crisis.
A return to solid growth has weakened public backing for independence.
Catalan leaders have pledged to proclaim a new republic within 48 hours if the “yes” side wins the referendum, regardless of turnout.