Deportation of convicted foreign nationals: article 89 of the Criminal Code

A sentence of more than one year can be replaced by deportation from Spain. We explain when article 89 applies, when it does not and how to prove your roots in Spain.
Celeste Pérez Bleda, criminal lawyer in Alicante
Celeste Pérez Bleda
Criminal lawyer · Bar No. 7301 ICALI

Updated: 24 November 2026

Airport boarding gate, image about the deportation of convicted foreign nationals
Quick answer

As a general rule, article 89 of the Spanish Criminal Code (Código Penal, CP) requires prison sentences of more than one year imposed on a foreign national to be replaced by deportation (expulsión) from Spain, with a ban on returning for five to ten years. It does not apply if deportation would be disproportionate, in particular because of the person’s roots in Spain (arraigo). Citizens of the European Union can be deported only if they pose a serious threat to public order or public security.

The deportation of convicted foreign nationals is one of the consequences that most worries anyone without Spanish nationality, sometimes even more than the sentence itself. A sentence of just over a year can mean leaving Spain and being unable to return for a decade, leaving behind your job, partner and children. The good news is that the law requires each case to be assessed. If you find yourself in this situation, our criminal lawyer for foreign nationals in Alicante service will look at your case from the outset.

The general rule in article 89

Article 89 of the Criminal Code, in the wording in force since 2015, draws distinctions according to the prison sentence imposed in the judgment, not the one sought by the prosecution:

Sentence imposed What the law provides Section
Up to one year Not replaced by deportation (an ordinary suspension may be possible) 89.1, by inference
More than one year Replaced by deportation. Exceptionally, the judge may order part of it, up to two thirds, to be served first, followed by deportation 89.1
More than five years (or several sentences totalling more) All or part of the sentence is served, and the remainder is replaced by deportation once that part has been served, or on moving to the open regime (tercer grado) or being granted parole (libertad condicional) 89.2

In all cases, if the convicted person moves to the open regime or is granted parole, the rest of the sentence is replaced by deportation. We explain how those stages work in the open regime and prison leave.

When it is decided

Whenever possible, the judge or court must decide on the replacement in the judgment itself. If it does not, once the judgment is final it will decide “as a matter of the utmost urgency”, after hearing the prosecutor and the other parties (article 89.3). That hearing is the opportunity to submit all the evidence of your roots in Spain.

Excluded offences

Sentences imposed for human trafficking (article 177 bis), for offences against workers’ rights under articles 312 and 313 or for offences against the rights of foreign nationals under article 318 bis are not replaced by deportation (article 89.9).

Proportionality and roots in Spain: when it does not apply

Article 89.4 provides that the replacement will not apply when, in view of the circumstances of the offence and the offender’s personal circumstances, “in particular their roots in Spain, deportation would be disproportionate”. This is the central point of the defence. The factors usually assessed are:

  • Length of residence in Spain and immigration status.
  • Family ties: partner, minor children, dependants.
  • Stable employment, social security contributions, housing and studies.
  • Absence of real ties with the country of origin.
  • Seriousness and circumstances of the offence committed.

All of this must be proven with documents: certificates of registration on the municipal register (empadronamiento), family record book, contracts, employment history or the children’s school reports. Statements without evidence are of little use.

Important: if you return to Spain before the entry ban ends, you will have to serve the sentence that was replaced, unless the judge exceptionally reduces it. And if you are caught at the border, the police will deport you directly and the ban period will start again from the beginning (article 89.7).

European Union citizens

For citizens of other European Union Member States, article 89.4 sets the bar much higher: deportation “shall apply only where the person represents a serious threat to public order or public security”, taking into account the nature and seriousness of the offence, their criminal record and their personal circumstances.

If they have also lived in Spain for the previous ten years, they can be deported only if they have been convicted of offences against life, liberty, physical integrity or sexual freedom carrying a maximum penalty of more than five years and there is a serious risk of reoffending, or of terrorist offences or offences committed within a criminal group or organisation. This affects the many EU residents living on the Costa Blanca. If you are here as a tourist, you may be interested in what happens when a tourist faces criminal charges in Alicante.

The other route: administrative expulsion under article 57 of the LOEX

In addition to criminal deportation, there is expulsion ordered by the authorities. Under article 57.2 of Organic Act 4/2000 on foreign nationals (Ley Orgánica 4/2000 de extranjería, LOEX), it is a ground for expulsion, following administrative proceedings, that the foreign national has been convicted, in Spain or abroad, of intentional conduct that constitutes an offence in Spain punishable by more than one year’s imprisonment, unless the criminal record has been cancelled.

  • Expulsion entails the termination of the residence permit (article 57.4).
  • The entry ban may not exceed five years, except where there is a serious threat, in which case it may be up to ten (article 58).
  • Long-term residents and other groups have enhanced protection, and before they are expelled their residence, ties, age and the consequences for their family must be assessed (article 57.5).
  • EU citizens and their family members are covered by Royal Decree 240/2007 (Real Decreto 240/2007), under which previous criminal convictions are not in themselves sufficient grounds for expulsion (article 15).

That is why clearing your criminal record as soon as possible is important for a foreign national. We explain this in how to clear a criminal record.

How to defend yourself against deportation

  1. From the investigation stage. Gather the documentation on your roots in Spain early and ask for it to be added to the case file, so that the judge can decide in the judgment.
  2. At trial or in a plea agreement. Consider any deal carefully: accepting a sentence of more than one year can trigger deportation, whereas a different classification or a sentence that does not exceed that threshold avoids it. Before accepting, read what a plea agreement in a speedy trial involves.
  3. At the hearing. If deportation is decided after the judgment, argue that it is disproportionate with specific evidence.
  4. Appeal. The decision on deportation can be appealed. Our criminal appeals lawyer in Alicante service checks whether the decision genuinely assessed your circumstances.

If deportation cannot be carried out, article 89.8 provides that the original sentence is to be served or, where appropriate, suspended. In the meantime, the judge may order the person to be held in a detention centre for foreign nationals (centro de internamiento de extranjeros, CIE) to secure it, within the limits of immigration law.

Convicted foreign nationals in Alicante

Many foreign residents live in the province of Alicante, from the EU and from non-EU countries, who have been integrated for years and for whom deportation would turn their whole life upside down. In practice, many of these decisions are taken in speedy trials held at the Alicante Duty Court, at Avenida de Aguilera, 53, according to the Generalitat Valenciana directory, or in the Criminal Sections of the Court of First Instance (Secciones de lo Penal del Tribunal de Instancia). Appeals against their judgments are decided by the Provincial Court of Alicante (Audiencia Provincial de Alicante), based in Plaza del Ayuntamiento, with sections sitting in Elche.

Celeste Pérez Bleda has more than 20 years’ experience in criminal law, and our team will assist you in your language, which is essential when such serious consequences have to be explained to the person and their family. We coordinate the criminal defence with the documentation on your roots in Spain and with your immigration situation so that no decision has effects you did not expect.

Every case is different. If you would like a criminal defence lawyer in Alicante to look at yours, Celeste Pérez Bleda’s team can also assist you in your own language.

Frequently asked questions

Will I be deported if I am sentenced to one year in prison?

Not under article 89 of the Criminal Code, which applies to prison sentences of more than one year. A sentence of exactly one year is not replaced by deportation and can be suspended if the requirements are met. Administrative expulsion under article 57.2 of the Immigration Act is a different matter: the authorities can start it on their own initiative and it requires its own defence.

How long will I be unable to return to Spain?

In criminal deportation, the judge sets a ban on returning of five to ten years, counted from the date of deportation, depending on the length of the sentence replaced and your personal circumstances (article 89.5). In administrative expulsion, the entry ban does not exceed five years, except where there is a serious threat to public order or public security, in which case it may be up to ten.

Does having children in Spain prevent deportation?

Not automatically, but it is one of the most important factors showing roots in Spain. Article 89.4 prevents deportation when it is disproportionate in view of the person’s circumstances, in particular their roots. You need to prove the real relationship with your children, living with them or contributing to their maintenance, together with your employment and length of residence.

Can a convicted European citizen be deported?

Only if they represent a serious threat to public order or public security, taking into account the offence, their criminal record and their circumstances. If they have lived in Spain for the previous ten years, only for serious offences against life, liberty, physical integrity or sexual freedom with a risk of reoffending, or for terrorism or organised crime (article 89.4).

What happens if I cannot be deported?

If replacement by deportation is ordered and cannot be carried out, for example because the country of origin does not provide documentation, article 89.8 states that the sentence imposed or the remaining period will be enforced or, where appropriate, enforcement will be suspended. That is why the strategy needs to be planned from the beginning.

If you are a foreign national facing criminal proceedings, deportation must be part of the strategy from day one, not just at the end. We will explain in your language what the real risk is and what we can do to protect your life in Spain; our team will assist you in English. You will find more information on our criminal defence for foreign nationals page, and you can message us on WhatsApp at 607 449 491, 24 hours a day: we will reply straight away.

Contents

Are you involved in criminal proceedings?

We explain your options and the next steps. Urgent assistance 24 hours a day.

Do you need a criminal lawyer?

We are available 24 hours a day. Your first case assessment is confidential.
Can I help you?