Skip to content

Costs and taxes of selling a property in Madrid

Every cost, line by line, so that there are no surprises on completion day at the notary. For owners in Madrid and abroad.

The costs of selling a property in Spain fall mostly on the seller. In Madrid you normally pay the notary’s fee for executing the deed, the certificates needed to sell (energy performance and owners’ association), the cancellation of any mortgage, the estate agency’s fee if you use one, the municipal capital gains tax (plusvalía) and income tax on any gain. Some of these costs can be agreed with the buyer; the taxes cannot. If you are not resident in Spain, the buyer also withholds 3% of the price on account of your tax.

Estate agency fees in Spain: how they work

There is no fee set by law. An agency’s fee is agreed with each owner, usually as a percentage of the sale price or as a fixed sum, plus VAT, and written into the agency agreement (hoja de encargo) before any work begins. Whoever instructs the agency pays, on the terms they have signed: when you sell, that is normally you. Some agencies also charge the buyer; if so, the buyer should know before making an offer, not at the notary.

The fee is usually paid when the sale completes, at the signing of the deed, although some agencies take part of it when the deposit contract (arras) is signed. Before signing an agency agreement, check:

  1. The fee, as a percentage or in euros, and whether VAT is included.
  2. When it is paid and what happens if the sale does not go through.
  3. Whether it is exclusive, for how long, whether it renews automatically and how it can be ended early.
  4. What exactly is included and what is charged separately.
  5. Who will look after your home: a name and a telephone number, not a department.

At Juvilma we do not publish a fee, because no two homes call for the same work: we give it to you in writing, before you sign anything.

Notary and Land Registry: who pays what

The Spanish Civil Code sets the default split: the seller pays for executing the deed, and the buyer pays for the first copy and everything after the sale, unless you agree otherwise. In practice, registering the sale at the Land Registry is usually paid by the buyer. If you want to share these costs differently, put it in writing in the deposit contract.

The energy performance certificate

You need one to sell. Its energy label must appear in any advertisement for the home, and a copy of the registered certificate is attached to the contract of sale. The seller commissions and pays for it, from a qualified technician. Order it early: without it, the home should not be advertised.

The owners’ association certificate

Before the signing, ask the building’s administrator for a certificate confirming that you are up to date with the owners’ association (comunidad de propietarios). Any debts are settled beforehand or at the signing itself.

Paying off and cancelling a mortgage

If a mortgage remains, it is repaid from the sale proceeds at the same signing. Repaying the debt does not remove it from the Land Registry: you ask the bank for a zero-balance certificate, which is free, and then cancel the charge at the Registry, which has its own notary and registry costs. The bank may charge a fee for early repayment, within the limits set by law.

Plusvalía: the municipal capital gains tax in Madrid

The plusvalía municipal is the tax Madrid City Council charges on the increase in the value of a home’s land when it is sold or inherited. On a sale it is paid by the seller, by self-assessment, within 30 working days of the signing, with one return per person and per property. If the seller is an individual not resident in Spain, the buyer pays it as the seller’s substitute.

The taxable base is the increase in the land’s value over the years you have owned the home, up to a maximum of twenty. It can be worked out in two ways:

  • The objective method: the cadastral value of the land multiplied by a coefficient that depends on the years of ownership.
  • The actual method: the difference between the land’s value on sale and on purchase, according to the deeds.

If the actual method gives a lower figure, you can ask for it to be applied. And if the land has not gained value between purchase and sale, the tax is not due: you must declare it and provide the deeds.

The maximum coefficients set by law change from 1 December 2026, and those Madrid applies depend on its tax ordinance, so for any figure use the official simulator of Madrid’s tax agency with your own details.

Capital gains tax on selling property in Spain: residents

If you are resident in Spain for tax purposes, the gain is taxed under income tax (IRPF) and declared in the following year’s return. The gain is the difference between:

  • The acquisition value: what you paid, plus improvements and the costs and taxes of the purchase, excluding mortgage interest.
  • The transfer value: what you receive, less the costs and taxes of the sale that you pay.

The gain is taxed in the savings base, in bands. Adding the national and regional scales together, for a resident the rate runs from 19% on the first €6,000 to 30% above €300,000, with intermediate bands of 21%, 23% and 27%. Keep the invoices for any renovation: they add to the acquisition value and reduce the gain.

Residents may be exempt in some cases:

  • Over 65 and selling your main home: the gain is exempt. The same applies to people with severe or major dependency (gran dependencia).
  • Reinvesting in a new main home: if you reinvest everything you receive in another main home, the gain can be excluded from tax; if you reinvest only part, the exemption is proportional. The deadlines and conditions are set by regulation.
  • Over 65 and buying a life annuity: the gain can be exempt if, within six months, you use what you receive to set up an insured life annuity, up to €240,000.

Royal Decree-law 29/2026, in force since 8 October 2026 and which, as at 14 October 2026, Congress had yet to ratify, changes what counts as a main home for the first two exemptions: the property counts if it was your main home at the time of sale or on any day in the previous two years. Confirm with your tax adviser whether this applies to your sale.

Selling a property in Spain as a non-resident

If you sell without being resident in Spain, two things change on the day of the signing:

  • The 3% withholding. The buyer must withhold 3% of the agreed price and pay it to the Spanish tax authority as a payment on account of the tax you owe on the sale. It is a payment on account, not necessarily the final figure.
  • The plusvalía. If you are an individual, the buyer pays the municipal capital gains tax as your substitute.

Plan for both when you work out what you will receive at the signing, and ask your tax adviser how your final tax on the gain is calculated and how any difference with the 3% is settled. The exemptions described above are those of Spanish income tax, for residents. Whether any of them applies to you as a non-resident is a question for your tax adviser.

Selling inherited property in Spain

If you inherited the home, its acquisition value for the sale is the value set under Inheritance Tax rules, capped at market value. That figure decides how much gain you will have when you sell. The plusvalía charged on the inheritance is separate from the one due when you later sell: on an inheritance it is paid by the heir, within six months of the death, extendable to a year at the heir’s request. In Madrid, inheriting the deceased’s main home carries a rebate on the tax due for descendants, ascendants, spouses and registered partners.

A checklist, so that nothing is forgotten

  1. Title deed or land registry extract (nota simple).
  2. The latest property tax (IBI) receipt.
  3. The registered energy performance certificate.
  4. The owners’ association certificate confirming you are up to date.
  5. If there is a mortgage, the bank’s certificate of the outstanding balance.
  6. The documents of the purchase and of any renovation, to calculate the gain correctly.

What is your home worth?

With a likely sale price in front of you, the rest of the sums can be done properly. Start there.

What owners ask us

  • How much tax will I pay if I sell my property in Spain?

    It depends on the gain, not on the price. The tax is charged on the difference between what you receive, less the costs of the sale, and what you paid, plus costs and improvements. For a resident, that gain is taxed at 19% to 30% in bands. A non-resident has 3% of the price withheld by the buyer on account. The municipal plusvalía is paid on top.

  • What fees do you pay when selling a house in Spain?

    Normally the notary’s fee for executing the deed, the energy performance certificate, the owners’ association certificate, the cancellation of any mortgage and the estate agency’s fee if you use one. The seller also pays two taxes: the municipal plusvalía and income tax on any gain. Some costs can be agreed with the buyer; the taxes cannot.

  • What is plusvalía?

    It is the municipal tax on the increase in the value of the land beneath a home, charged when the home is sold or inherited. In Madrid it is paid by self-assessment within 30 working days of a sale. The seller pays it, unless the seller is an individual not resident in Spain, in which case the buyer pays it on the seller’s behalf.

  • How much is plusvalía tax in Madrid?

    There is no single figure. It depends on the cadastral value of the land, the years you have owned the home, up to twenty, and the method used: the objective one, with coefficients, or the actual one, based on the deeds, whichever is lower if you ask. The coefficients change from 1 December 2026, so use Madrid’s official simulator with your own details.

  • Do non-residents pay tax when selling property in Spain?

    Yes. The buyer withholds 3% of the price and pays it to the Spanish tax authority on account of the seller’s tax on the gain, and pays the municipal plusvalía as the seller’s substitute. The 3% is a payment on account, not necessarily the final amount, so ask your tax adviser how your final figure is worked out before you sign.

  • Who pays the estate agent’s fee in Spain, the buyer or the seller?

    Whoever instructs the agency, on the terms they have signed. On a sale it is usually the owner, who signs the agency agreement. If an agency also wants to charge the buyer, it should say so before the buyer makes an offer. There is no fee fixed by law, so always ask who pays what before you sign anything.

Let’s talk about your home.

We help you put the numbers in order before you sell. For your tax return, speak to your tax adviser.