The Spanish government has vowed to block plans by parties in Catalonia to hold a referendum on independence on 9 November of next year. The poll will not be held, Justice Minister Alberto Ruiz-Gallardon told journalists moments after Catalonia's President, Artur Mas, announced a deal.
Mas said agreement had been reached on the date and on two questions. Voters would be asked if they wanted Catalonia to be a state and if they wanted it to be an independent state. He announced that an agreement had been reached in principle and had still to be approved formally by the parties internally.
Both Spain's ruling conservatives, the Popular Party of Prime Minister Mariano Rajoy, and the Socialist opposition have long made it clear that they oppose a referendum.
Under the current Spanish constitution, referendums can only be called by the national government in Madrid, not by the governments of Spain's 17 autonomous communities, of which Catalonia is one.
Mr Mas has said that there is time to comply with laws and democratic processes.
Catalonia is one of Spain's most developed regions, with a population of 7.5 million. It already has a wide degree of autonomy but the recent economic crisis has fuelled Catalan nationalism. In September supporters of independence formed a human chain across the region.
Mr Mas has previously said that if Madrid blocks a referendum, he will turn regional elections - due in 2016 - into a vote on independence. Opinion polls suggest Catalans are evenly split over independence.
The EU and Nato have warned that Catalonia would be excluded if it broke away from Spain. Nationalists in another Spanish region, the Basque Country, won regional elections there last year.