Illegal builds and the AFO in Andalucía
Many homes on the Costa del Sol have something built without a licence: a terrace closed in with glass, an extra room, a pool, sometimes the whole house on rustic land. When you buy the home, you buy the problem. The town hall's powers over the works pass to you as the new owner.
Not every unlicensed build is a reason to walk away. After a time limit, many can no longer be demolished and can be recognised under an AFO. But an AFO is not a licence, and it limits what you can do with the home. Find out which situation you are in before you offer.
What counts as an illegal build
Any work done without the licence it needed, or beyond what the licence allowed. On this coast the usual ones are:
- A terrace closed in with glass or aluminium to make an extra room.
- An extension, a roof terrace built up, or a garage turned into living space.
- A pool, a guest house or outbuildings that never had a licence.
- A whole house on rustic (non-developable) land, built without one.
The six-year limit
Andalusia's planning law, the LISTA (Ley 7/2021), gives the town hall a time limit to act against unlicensed works and order them put right, which can mean demolition. It is generally six years from when the works were finished. Once it has passed, the works can no longer be demolished for that reason, but they do not become legal.
There is no time limit on specially protected land, such as protected rustic land, public land like the shoreline, and parks and green spaces, and in some other cases. There, the risk of a demolition order does not fade with age. Proving when works were finished is not always easy: dated photos, the official property record and old aerial images are often used. Ask your lawyer which rule applies to this home.
What an AFO is, and what it allows
AFO stands for asimilado a fuera de ordenación: treated as outside the planning rules. It is a resolution by the town hall, asked for by the owner, recognising that the time limit has passed and that the building is safe and fit to live in. It usually needs an architect's report and a fee.
With an AFO the home can be lived in and can be recorded in the Registro de la Propiedad. Connections to water and power may be allowed. Works are limited, generally to what keeps the building in good repair: no extensions. Fewer banks will lend on it, and some buyers will not consider it, which matters when you sell.
Occupation and utility contracts
A home built with a licence is allowed to be lived in through a first occupation licence (licencia de primera ocupación) or, in Andalusia, often a declaración responsable de ocupación filed with the town hall. Water and power companies ask for it to open new contracts, and a holiday let needs it to be registered.
If the seller can't show one, or the AFO resolution instead, ask why. A home on supplies that were connected on someone else's contract, or on a builder's temporary supply, is a warning sign.
The clues in the advert
The most common clue is size. When the advert says 95 m² and the official property record says 84 m², agents are often counting an enclosed terrace, a share of common areas or a storage room. If the extra space comes from works without a licence, it can't be legalised cheaply and may have to be removed. A mismatch between the land registry and the official record points the same way: works done after the title was written and never declared.
Other clues: a pool or rooms in the photos that aren't on the record, words like “potential to extend”, and a country house sold as a finca on rustic land. Paste the advert into Nelo and it puts the advert next to the official record and flags each difference.
What to ask for before you offer
Ask the agent, in writing, for the documents below. Don't offer on a home on rustic land, or one with large unexplained extra space, without a lawyer's opinion.
- The building licence and the first occupation licence or declaración responsable, or the AFO resolution.
- The licence (obra menor or mayor) and the community's authorisation for any enclosed terrace.
- The town hall's planning report on the home (informe or certificado urbanístico), which shows the land class and any open proceedings.
- A Nota Simple, to see whether the AFO or any planning proceedings are noted on the title.
The checklist: before you offer on a home in Spain
Every step from the first viewing to signing the arras, on two pages to print or keep on your phone.
Questions people ask
What is an AFO certificate in Spain?
It is a town-hall resolution declaring that a building put up without a licence is asimilado a fuera de ordenación: too old to be demolished for that reason, and safe to live in. It lets the home be lived in and registered, but limits works on it. It is not a licence.
Can I get a mortgage on a home with an AFO?
Sometimes, but fewer banks will lend and they may lend less. Ask lenders before you offer, not after. Buying with cash avoids the question but not the limits on works or resale.
Can the town hall demolish a house I have bought?
If the works are within the time limit, generally six years from completion, or on specially protected land where there is no limit, yes. The obligation passes to you as the new owner. Ask your lawyer to check before you sign anything.
Is a closed-in terrace a problem when buying?
It can be. It needs a licence and usually the community's approval. Without them it is an unlicensed work, which can affect the mortgage valuation, insurance and resale. Ask for both papers.
What is a first occupation licence?
It confirms that a building was built as licensed and can be lived in. In Andalusia it is often replaced by a declaración responsable de ocupación filed with the town hall. Utility companies ask for it to open contracts.
Read next
What to check before you make an offer or pay a deposit on a Costa del Sol home: the official record, the Nota Simple, licences, debts, letting rules and costs.
The Nota Simple is the land registry extract for a Spanish home: owners, size, mortgages and seizures. What it shows, what it misses and how to order one.
A lawyer isn't legally required to buy in Spain, and the notary isn't on your side. What an independent lawyer does, the typical cost and when to hire one.
Can you let a home to tourists on the Costa del Sol? The Andalusian register, Málaga's freeze, the community vote, and whether a licence passes to you.
A guide, not legal advice. Rules change: have your own lawyer confirm anything you rely on.