Contains AI-generated informationMore information

Investment income and capital gainsArticle 7 of 12 · 5 min read

Using investment losses against gains in Spain

How to use investment losses to cut your Spanish tax: what they can be netted against, how long you can carry them forward, and how to avoid the repurchase rule that blocks a loss. For tax residents who sell investments at a loss.

Key rules

  • Offset limit: A negative balance in one group can reduce the other group only up to 25%.
  • Carry-forward: Leftover net losses can be used for 4 years, oldest first.
  • Repurchase rule: Buying the same security within two months before or after a loss sale blocks the loss; for unlisted securities the period is one year.
  • Blocked loss: A blocked loss counts again when you sell the repurchased securities.

The short answer

A loss from selling investments first cancels your gains from other sales in the same year. Any loss left can reduce your interest and dividends, up to a cap. What is still left carries forward. One trap can block the whole loss: buying the same investment back too soon.

How losses are netted

Your savings income sits in two groups. One group is gains and losses from selling investments. The other is interest and dividends.

  1. Net the sales against each other for the year.
  2. Net your interest and dividends together as a separate balance.
  3. If one group ends negative and the other positive, offset the negative against the positive. The offset is limited to 25%.

The 25% limit is the same in both directions. If a group stays negative after this, carry it forward.

Carrying a loss forward

You can carry a net loss forward for 4 years. Use the oldest losses first. Note the year of each leftover loss so you can track when it runs out. Carried-forward sale losses are used against later gains from sales. Carried-forward negative interest and dividend balances are used first against that same kind of income. The 25% limit still applies to offsets between the two groups.

The repurchase rule

Your loss does not count if you bought the same security within two months before or after the sale, for listed securities. For unlisted securities the period is one year.

  • Count both directions: buying before the sale also triggers it.
  • It covers units of the same fund and the same ETF. Many advisers treat a different fund tracking the same index as a different investment, but check your case with a tax adviser.
  • The loss is not gone. It is blocked, and counts when you later sell the repurchased securities. If you buy again within the period around that later sale, it is blocked again.
  • Keep the dates of the sale and purchase of any blocked loss so you can claim it later.

Practical order

Before selling at a loss, check your recent purchases of the same security. After selling, wait out the period before buying it back. The timeline and checklist below walk through the steps.

Timeline and deadlines

  • Check for a purchase of the same security before you sell at a loss: in the two months before the sale for listed securities, or the year before for unlisted ones

  • Offset the loss against gains from sales in the same year: when you file your tax return for the year of the sale

  • Offset any remaining loss against interest and dividends, up to 25% of their balance: in the same tax return

  • Carry forward what is left and use the oldest losses first: over the following 4 years

  • Count a blocked loss when you sell the repurchased securities: when you later sell them, if no new repurchase blocks it again

Checklist

  • Add up your gains and losses from sales of investments for the year, and net them against each other first.

  • Add up your interest and dividends for the year as a separate balance.

  • Offset a negative balance in one group against the positive balance of the other, up to 25%.

  • List any loss left over with its year, so you can carry it forward for 4 years and use the oldest first.

  • Check whether you bought the same security, or units of the same fund or ETF, within two months before or after each sale at a loss.

  • For unlisted securities, check for a repurchase within one year before or after the sale.

  • Keep the sale and purchase dates of any blocked loss, so you can claim it when you sell the repurchased securities.

What to watch out for

  • Buying back too soon blocks your loss: If you buy the same security within two months before or after a sale at a loss (one year for unlisted securities), the loss is not counted that year. Wait out the full period before buying it back, or check the dates before you sell.

  • Funds and ETFs count too: Units of the same fund or ETF are treated as the same security, so a quick switch back into it triggers the block. If you want to stay invested, check whether a different fund would count as a different security before you sell.

  • A blocked loss can be blocked again: A blocked loss is only counted when you sell the repurchased securities, and a new repurchase around that sale blocks it again. Keep dates for every purchase and sale so you can see when the loss is free to use.

Frequently asked questions

Can I sell at a loss and buy the same fund back straight away?

Yes, you can buy it back, but the loss is not counted if you repurchase within two months for listed securities, or one year for unlisted ones. The loss is not lost: it is counted when you later sell the repurchased units, as long as no new repurchase blocks it again.

Does the two-month rule apply to funds and ETFs?

Yes, the rule covers units in investment funds and ETFs when you buy back the same fund or the same security. Many people treat a different fund as a different security, even if it tracks the same index, so swapping to another fund is the usual way around it.

In what order are my older losses used against gains?

Your oldest losses are used first, and each one can be used for 4 years.

Can a loss on a sale reduce tax on my interest and dividends?

Yes, but only up to 25% of the balance of your interest and dividends in a year. Anything left over carries forward for 4 years.

Need certainty before you act?

For important relocation decisions, speak with a qualified human specialist.

Consult with a human specialist

For decisions that depend on your own circumstances, a qualified human professional should look at your case. Tell us what you need help with and we will reply by email.

Always verify important information with the relevant official authority or a qualified adviser before acting. This website uses large language models together with various public data sources, official government documents and other established sources. Due to the amount of data on this website, some information might be wrong. Information may also be incomplete or outdated.

What matters to me

Tell us who you are and what you care about. Fit scores and rankings across the site follow your answers.