An illegal build in Spain is a property, or part of one, that was built without the required planning licence or in breach of the licence it had. It can bring fines, a demolition order and problems when you resell, and some cases cannot be fixed. The best protection is to ask the town hall for a certificate that there is no open planning infringement, check the first-occupation licence and compare the deed, the land registry and the cadastre with the real property before you pay a deposit. Extensions that do not appear on the deed and houses on rural land are the classic red flags. This guide explains the documents, the red flags, the Andalucía AFO status and what to do if you find a problem. It is general information, not legal advice, and rules differ by region and municipality.
What counts as an illegal build?
There are several situations, and they are not all equally serious:
- A whole house built without a licence, often on rural land where building is not allowed.
- An extension, pool, terrace or extra floor added to a legal house without permission or beyond what the licence allowed.
- A building that is not registered in the land registry or cadastre, even if it was built legally.
- A change of use, for example from storage to a home, without authorisation.
The consequences and the possible fixes depend on which case you have. Do not accept that “everyone does it here” or that the seller’s agent says everything is legal, because agents may not know.
Which documents should you check?
| Document | What it tells you | Limit |
|---|---|---|
| Certificate of no planning infringement (certificado de inexistencia de infracción urbanística) | That the town hall has no open planning infringement file for the property | Apply at the planning office of the town hall; one guide says it takes about 15 days and the fee varies |
| First-occupation licence (licencia de primera ocupación, sometimes cédula de habitabilidad) | That the home was licensed for living in when built | Very old homes may not have one |
| Land registry record (nota simple) | Owner, description, size and charges as registered | Does not show pending planning problems |
| Deed and cadastre | The size and layout on paper | Compare with the real property |
| Architect’s report | What is really built, compared with the licences | Cost depends on the property |
The certificate of no infringement is described as the most reliable single check. You need a location plan, a recent property tax receipt or a cadastral certificate and proof of payment. Start it before you sign the arras contract, because the wait can be longer than the time the seller gives you.
What are the red flags?
- Rooms, floors, terraces or pools that exist but do not appear on the deed.
- A home on rustic or rural land, where building is often prohibited.
- An advertised size that is much larger than the registered size. For example, a villa advertised at 150 m² with 110 m² in the registry has 40 m², or about 27%, that is not recorded, and you need to know why.
- No first-occupation licence or an old licence that does not match the building.
- A seller who refuses to give you the documents or says you do not need them.
- A very low price for the area, or pressure to sign before the checks.
- A request to declare a lower price in the deed.
What can go wrong?
Published guidance names several risks. A property can be subject to a pending court order for demolition. You can find it hard to resell, or to get a mortgage on the part that is not registered. Some cases can be legalised, but it can be expensive and may require a reform project and a legalisation file prepared by an architect, and some properties cannot be fixed, especially if they were built illegally from the start or are earmarked for demolition. The sources we read do not give fine amounts or time limits for enforcement, and those depend on the region and the case, so ask your lawyer rather than rely on a figure you find online.
What is the AFO status in Andalucía?
In Andalucía, a building that was built without the required licence can sometimes obtain the status asimilado a fuera de ordenación (AFO), regulated by Law 7/2021 (LISTA) and Decree 550/2022. A law firm that explains it stresses the key point: recognition is not legalisation, and it does not make the original construction lawful. According to that guide, the conditions include six years since the building was completed with no active sanction or demolition procedure, ordinary rural land that is not specially protected, minimum safety and habitability conditions, and consolidated use. AFO does not automatically allow extensions or new works, and access to water, sewerage and electricity depends on the plot and municipality. A true ruin without a roof or legal building history is generally treated as new construction on rural land, which is a harder position. Other regions have their own rules. Our guide to choosing an area reminds you that planning rules differ by region and town.
What is the step-by-step plan?
- Hire an independent lawyer before you make an offer (see the lawyer fees guide).
- Ask the seller for the deed, the cadastral certificate, the property tax receipt and any licences.
- Request the nota simple and compare the registered description with the property.
- Ask the town hall for the certificate of no planning infringement.
- For an older home, an extension or a rural property, hire an architect to compare the building with the licences.
- Put clauses in the deposit contract: the seller guarantees the documents, and you can recover the deposit if the checks fail.
- Do not complete until the checks are satisfactory, and follow the 12-step guide.
What should you do if you find a problem?
Stop and ask your lawyer. You have three realistic options: walk away, ask the seller to fix the problem before the deed, or negotiate the price and a contract that allocates the risk. If the seller proposes to legalise after the sale, be careful, since the cost and the outcome are uncertain and the risk becomes yours. Get a written estimate from an architect, include the cost and the time in your decision and do not rely on verbal promises.
What are the common mistakes?
- Paying a deposit before the planning checks.
- Relying on the registry alone, which does not show pending planning problems.
- Accepting the agent’s word that everything is legal.
- Buying a rural house without checking the land classification.
- Ignoring the gap between the advertised size and the registered size.
- Assuming that a utility connection or a mortgage valuation proves legality.
Does the bank or the notary check that the home is legal?
Do not assume so. A bank valuation is made to decide how much the bank will lend, not to confirm that every room has a licence. A notary checks the identity of the parties, the deed and the registry description, but you should not treat the signing as proof that the building matches its planning permissions. The practical lesson is that the legal check is your job, done with your own lawyer and, where the building is old or has been altered, an architect, before you commit money.
How should the contract protect you?
Ask your lawyer to include in the deposit or arras contract a statement that the seller guarantees the home has the licences it needs, a deadline for you to receive the town hall certificate, and a clause that returns your deposit if the checks show a problem. A seller who has nothing to hide will usually accept a reasonable clause. A seller who refuses is giving you information too.
Which properties need extra care?
Take most care with rural houses, homes that have been extended, properties with a pool or guest house that were added later, and cheap plots sold with “permission to build” that nobody can show you. Newer apartments in a regular development are usually simpler, but the same documents are still worth requesting.
Frequently asked questions
How do I know if a Spanish property is legal?
Ask the town hall for the certificate of no planning infringement, check the first-occupation licence, and compare the deed, the land registry and the cadastre with the real property.
What is the first-occupation licence?
It shows that the home was licensed for living in when it was built. Very old homes may not have one, so ask your lawyer what is needed for your property.
Can an illegal extension be legalised?
Sometimes, but it can be costly and may need an architect’s project and a legalisation file. Some cases cannot be fixed.
What is AFO in Andalucía?
A status for some unlicensed buildings that recognises their existence without making the original construction lawful. It does not automatically allow extensions.
Does the nota simple show planning problems?
No. The land registry does not show pending planning issues, which is why you also need the town hall certificate.
Sources
Official sources (check these for the current rule):
- Land registry online service (Registradores de España)
- Boletín Oficial del Estado (BOE)
- General Council of Spanish Notaries
Also cross-checked against published guides, because practice varies between notaries, registries and banks:
- The Local Spain: how can I find out if my Spanish property is legal?
- Costa Luz Lawyers: AFO in Andalusia, recognising an unlicensed rural building
- Immoabroad: no infracción when buying property in Spain
This is general information, not legal or tax advice. Rules and rates change, and your situation may differ. Confirm the figures with the tax authority and a qualified lawyer or tax adviser before you commit.