Algeria suspended a 20-year-old friendship treaty with Spain that committed the two sides to cooperation in controlling migration flows, and also banned imports from Spain, escalating a row over Madrid's stance on Western Sahara.
Algerian state media reported the suspension of the treaty without citing any reason, though Algeria had in March withdrawn its ambassador to Spain for consultations because of the Western Sahara dispute.
Spanish diplomatic sources said Spain regretted the decision but remained committed to the content and principle of the treaty.
Separately, Algeria's banking association issued a statement telling banks that imports of goods and services from Spain were stopping because the treaty was suspended.
The 2002 treaty called on both sides to "deepen their cooperation in the control of migratory flows and the fight against trafficking against human beings" according to the text recorded in Spain's official journal.
On Wednesday, 113 undocumented migrants arrived in Spain's Balearic islands, a route that Spanish authorities said tended to be used by boats coming from Algeria.
Migrant flows have sharply increased across the Mediterranean this year as the pandemic and Russia's invasion of Ukraine has hit the global economy.
Algeria was angered when Spain said in March it supported a Moroccan plan to offer autonomy to Western Sahara. Algeria backs the Polisario Front movement seeking full independence for the territory, which Morocco regards as its own and mostly controls.
A former Algerian official told Reuters that Algiers believed the Spanish government had decided not to preserve good ties with Algeria.
Algeria is a key gas supplier to Spain, but Algerian President Abdelmadjid Tebboune has previously said he would not break the supply contract over the row.
Spanish Foreign Minister Jose Manuel Albares said there was no indication that had changed and Spanish Energy Minister Teresa Ribera said Algeria's gas supply conduct had been exemplary.
Algeria is expected to review prices for any new gas contract with Spanish firms, a source familiar with the matter told Reuters. The current contract is long-term with prices well under the current market level, the same source, who asked not to be identified, said.
Since the Western Sahara conflict flared again in 2020, nearly three decades after a ceasefire, relations between Algeria and Morocco have sharply deteriorated.
Spain's shift towards Morocco's stance on Western Sahara ended a dispute between Madrid and Rabat last year involving both the disputed territory and migration.