Gestoría guides

Trading in the Renta: how to declare shares, ETFs, CFDs, forex and options

Last updated 1 October 2026 · Reviewed by Jaime Piñeira Pardo, lawyer registered with the ICAM bar, no. 138826 · English version of our Spanish guide.

The short answer

Trading is declared in the Renta as a capital gain or loss in the savings base, taxed from 19% to 30%. Every trade closed in the year counts, even if the money remains with the broker. Shares and ETFs are calculated by FIFO; CFDs, forex and options by the result of each position. Losses are offset over four years.

We handle the whole procedure for you, from start to finish.

You describe your case in a chat and sign; we file it with the Spanish authorities. Fixed price from €199.00 (21% VAT included), plus the tasa (official fee) where there is one.

See the procedure

What is new, and the law that applies

  • Since 1 January 2025, the part of the savings base that exceeds €300,000 is taxed at 30%, and not at 28% as before. The change is from Ley 7/2024, of 20 December. It applies to the 2025 Renta, filed in 2026, and to the 2026 one, which is filed in 2027.
  • Form 720: since the CJEU judgment of 27 January 2022 (case C-788/19) and Ley 5/2022, filing it late or incorrectly is penalised under the general regime of the Ley General Tributaria.

How is trading taxed in the Renta tax return?

If you trade with your own money, every purchase and sale of shares, ETFs, CFDs, currencies, futures or options produces a capital gain or loss: the difference between what you paid and what you obtained upon closing. The Ley 35/2006 (the Spanish Personal Income Tax Act) defines them as variations in the value of your wealth that appear when its composition is altered (artículo 33).

These gains and losses go to the savings taxable base, because they arise from transferring wealth elements (artículo 46). They are not added to your salary: they have their own scale, from 19% to 30%, which is the same in all common regime autonomous communities.

The moment that counts is the closing of the trade, not the withdrawal of the money. The law attributes gains and losses to the year in which the wealth alteration occurs (artículo 14.1.c). If you closed a position with a profit in December and left the balance with the broker, that profit goes into the Renta for that year.

Positions that remain open on 31 December are not declared yet. Dividends and broker interest are something else: returns on movable capital, also in the savings base but in a different balance.

How is the gain calculated when selling shares and ETFs?

The gain is the transfer value minus the acquisition value (artículo 34). For listed securities, the transfer value is the quoted price on the day of the sale, or the agreed price if it is higher (artículo 37.1.a).

Broker commissions count. Purchase commissions are added to the acquisition value and sale commissions are subtracted from the transfer value, because the law includes the expenses and taxes inherent to the transaction (artículo 35). Platform subscriptions, courses or market data are not transaction expenses and are not deducted.

When you have bought the same share or the same ETF several times, FIFO applies: it is understood that you sell first the ones you bought first (artículo 37.2). You cannot choose the batch or use the average price shown by the broker application (consultations V0842-21 and V1185-18 of the DGT, the Spanish Directorate-General for Taxes).

If you trade in dollars or another currency, the purchase and sale are converted to euros using the exchange rate of the date of each one. Thus, a share that has not gone up in dollars can give you a gain or loss in euros just because of the exchange rate.

ETFs are taxed like shares when you sell them, but they do not benefit from the tax-free transfer (traspaso) available to investment funds: moving from one ETF to another means selling and buying, and the gain is declared that year. Furthermore, the sale of an ETF has no withholding tax, so everything is adjusted in the Renta.

Managora does this calculation in its trading tax report: it converts currencies, applies FIFO and the two-month rule and gives you the figures for each box in Renta Web. You can see the updated amount on the file.

What is the two-month rule and when does it block a loss?

It is the rule that prevents selling at a loss and repurchasing immediately just to lower the tax. If you sell listed securities at a loss and have bought homogeneous securities (the same share or the same ETF) in the two months before or after the sale, that loss is not computed at the time of the sale (artículo 33.5.f). For unlisted securities, the period is one year (artículo 33.5.g).

The loss does not disappear: it is postponed. It is integrated when you sell the repurchased securities that remain in your portfolio. The DGT explains it as a two-phase procedure in consultation V0842-21, and already analysed the case of someone who buys and sells the same share several times in the year in V0913-08.

The typical risk is in December: selling in the red to offset gains and repurchasing a few days later. That loss is of no use to you in the Renta for the year if you keep the repurchased securities on 31 December.

The rule is written for securities and participations. If your losses come from CFDs, forex or options, review the specific case before applying or discarding it.

How are CFDs, forex, futures and options declared?

CFDs and contracts on currency pairs (forex) yield capital gains or losses, and the DGT indicates that they are recorded in the section for gains and losses derived from the transfer of wealth elements (consultation V0917-14, on CFDs on indices and currency pairs). Under the current law, they go to the savings base.

Forex with a foreign broker is treated the same way. Consultation V1342-14 analyses the case of an individual who traded with a Cypriot investment services company through a dollar account, and classifies it as capital gains and losses.

Options also generate capital gains or losses in the savings base, attributed to the year in which the position is closed, exercised or expires (consultation V1946-20, on options in the official Spanish market and on other platforms). The premium you collect when selling an option is not declared on the day you collect it, but when the position is closed or expires. Futures follow the same logic: the result upon closing counts.

For a retail investor in Spain, CFDs have limited leverage (between 30:1 and 2:1 depending on the underlying asset), automatic closure when the margin falls to 50% and protection against negative balances, due to the measures of the CNMV (the Spanish National Securities Market Commission) of June 2019. With a regulated broker, your loss should not exceed what you deposited.

How are trading losses offset in the Renta?

Within the savings base there are two balances (artículo 49). One gathers capital gains and losses: shares, ETFs, funds, CFDs, forex, options and cryptocurrencies. Another gathers returns on movable capital: dividends, interest and coupons.

First, everything is offset within each balance. If gains and losses result in a negative figure, that negative amount is subtracted from the positive balance of dividends and interest with a limit of 25% of that balance. It works the same way in reverse.

Whatever is left over is carried forward to the following four years, in the same order. It must be offset in the maximum amount allowed each year: you cannot save it for a better year (artículo 49.2). After the fourth year, the loss is lost.

Trading losses are not subtracted from your salary or from rent: those incomes go to the general base, and the two bases do not mix. That is why it is advisable for every loss to appear on a tax return, even if you are not obliged to file one that year.

What happens with dividends and withholding taxes from a foreign broker?

A foreign broker does not apply Spanish withholding tax to you: neither on sales nor on dividends. Everything you earn is paid in the Renta, all at once, in June.

Dividends are taxed as returns on movable capital (artículo 25.1.a) for their gross amount, before the withholding tax of the country of origin. If that country withheld tax from you, you can apply the deduction for international double taxation (artículo 80): you deduct the lesser of what was paid abroad and what results from applying your effective average savings rate to that dividend.

If the country of origin withheld more from you than the double taxation agreement with Spain allows, the excess is not recovered in the Spanish Renta: it is claimed in that country. For United States shares, the W-8BEN form serves for the broker to apply the agreement rate from the beginning.

Do I have to file form 720 for my foreign broker?

Form 720 is an informative return: it does not pay tax, it only communicates to Hacienda (the Spanish Tax Agency, AEAT) what you have outside Spain. You are obliged to file it if, on 31 December, any of its blocks exceeds €50,000: accounts abroad, securities and rights deposited or managed abroad (shares, ETFs, funds), or real estate.

It is filed between 1 January and 31 March of the following year. Once filed, it only needs to be filed again if the block increases by more than €20,000 compared to the last return, or if something declared is cancelled or you cease to be the owner.

Since the judgment of the Court of Justice of the European Union of 27 January 2022 and Ley 5/2022, a 720 filed late or with errors is penalised under the general regime of the Ley General Tributaria (the Spanish General Tax Act), not with the specific fines that existed before.

Cryptocurrencies custodied outside Spain do not go on the 720, but on form 721, with the same threshold of €50,000. If your foreign broker has a branch in Spain and custodies the securities there, the block might not count: check it with the entity's statement.

Managora prepares and files form 720 with the valuation of each block on 31 December: you can see the updated amount on the file.

What if I trade with a funded account or make a living from trading?

Making a living from trading with your own money does not make you an autónomo (freelancer) for Renta purposes. Economic activity requires organising production means or human resources on your own account to produce or distribute goods or services (artículo 27), and buying and selling your own securities does not fit there. Even if you trade daily and it is your only income, it remains a capital gain or loss in the savings base.

Funded accounts (prop firms) are something else. You trade the company's capital, not your own, and what you collect is a part of the profits you generate for it. That payment does not arise from a variation in your wealth: Hacienda's criterion is to treat it as a return from an economic activity, in the general base, with the progressive scale and not with the savings scale.

As an activity, you can subtract linked expenses, such as the exam or challenge fee, and census registration and Seguridad Social (the Spanish Social Security system) are considered. Managora separates in your statements what is a capital gain from what is an activity and prepares the tax return with that criterion.

Step by step

  1. 1

    Download the annual report and trading history from each broker(In January or February, when the broker publishes the report)

    Closed trades of the year with date, asset, quantity, price, currency and commissions, plus the certificate of dividends and withholding taxes. The application summary is not enough: it usually uses an average price.

  2. 2

    Convert everything to euros using the exchange rate of each date(Before calculating anything)

    Purchase at the exchange rate of the purchase day, sale at the sale day rate. If you keep a balance in foreign currency, also note when you changed it to euros.

  3. 3

    Calculate shares and ETFs by FIFO(With the complete history, including previous years)

    Pair each sale with the oldest purchases of the same security. Purchase commissions to the cost; sale commissions, subtracted from the amount obtained.

  4. 4

    Review the two-month rule(Before filling in the Renta)

    Mark each sale at a loss where you bought the same security two months before or after: that loss is postponed.

  5. 5

    Add up the result of CFDs, forex, futures and options(Before filling in the Renta)

    Net result of each position closed in the year, with its commissions and financing. Positions open on 31 December are not included.

  6. 6

    Recover pending losses from the previous four years(Before filling in the Renta)

    They are in the annex of your previous tax returns. They are applied first against the gains of the year and, if there is a surplus, against dividends and interest up to 25%.

  7. 7

    Fill in Renta Web and apply double taxation(During the Renta campaign, normally from April to 30 June)

    Shares and ETFs, in the traded shares section; CFDs, forex and options, in the other wealth elements section; foreign dividends, in movable capital with the deduction for international double taxation. If you prefer not to do it yourself, Managora files your form 100.

  8. 8

    Check if you have to file form 720(From 1 January to 31 March)

    Add up the value of your securities and the balance of your accounts outside Spain on 31 December, by blocks. If a block exceeds €50,000, or goes up by more than €20,000 since the last 720, it must be filed.

A worked example

Person resident in Spain with a salary (which absorbs their personal minimum), without other deductions, and a foreign broker that does not withhold tax. In 2026 they make these trades; they have €900 of capital losses from 2023 uncompensated because in 2024 and 2025 they had no capital gains, dividends or interest.

  • Shares: buys 10 at €150 plus 4 in commission (€1,504) and then 10 at €180 plus 4 in commission (€1,804, 180.40 per share). Sells 15 at €200 minus 4 in commission: €2,996.
  • FIFO: cost of the 15 sold = 1,504 (first complete batch) + 5 x 180.40 (902) = €2,406. Gain: 2,996 - 2,406 = €590.00.
  • ETF: sells at a loss of €400 and repurchases the same ETF three weeks later. Due to the two-month rule, and since on 31 December they still have that ETF, that loss is not computed in 2026: it will be integrated when they sell it.
  • CFDs on indices: closed positions with gains of €3,000 and losses of €1,800. Net: €1,200.00.
  • Options: premium of €250 for selling a put that expires unexercised. Gain: €250.00.
  • Forex: net loss of €500.00.
  • Balance of capital gains and losses: 590 + 1,200 + 250 - 500 = €1,540.00.
  • Offset of 2023 losses: 1,540 - 900 = €640.00.
  • Dividends from United States shares: €600 gross, with €90 withheld in the United States (15%). Return on movable capital: €600.00.
  • Savings liquidable base: 640 + 600 = €1,240.00. Everything falls into the first bracket: 1,240 x 19% = €235.60.
  • Double taxation: average savings rate 235.60 / 1,240 = 19.00%. Limit: 600 x 19.00% = €114.00. Paid abroad: €90.00. The lesser is deducted: €90.00.
  • Tax due for the savings part: 235.60 - 90.00 = €145.60.

For their 2026 trading they pay €145.60 in the Renta filed in 2027. The 2023 losses are exhausted and the €400 ETF loss remains pending until they sell the repurchased participations.

Savings base scale from 1 January 2025 (state and regional combined, common territory)

Savings liquidable baseRate applicable to the bracket
Up to €6,00019%
From €6,000 to €50,00021%
From €50,000 to €200,00023%
From €200,000 to €300,00027%
More than €300,00030%

How each trading product is declared in the IRPF

ProductType of incomeBaseWhen it is declaredWithholding tax if the broker is foreign
SharesCapital gain or loss (FIFO)SavingsWhen sellingNo
ETFsCapital gain or loss (FIFO), without transferSavingsWhen sellingNo
CFDsCapital gain or lossSavingsWhen closing the positionNo
ForexCapital gain or lossSavingsWhen closing the positionNo
Options and futuresCapital gain or lossSavingsWhen closing, exercising or expiringNo
DividendsReturn on movable capitalSavingsWhen they become dueOnly that of the country of origin
Payments from a funded accountReturn from economic activityGeneralWhen accruedNo

Trading with your money or with a funded account: how the Renta changes

Trading with own moneyFunded account (prop firm)
What it is for HaciendaCapital gain or lossReturn from economic activity
IRPF baseSavings, from 19% to 30%General, progressive scale with your salary
LossesOffset against gains and up to 25% of dividends, four yearsThey are expenses and negative result of the activity
Deductible expensesOnly commissions and expenses of each tradeExpenses linked to the activity, such as the challenge fee
Census registrationNoIt is considered
Where it goes in Renta WebCapital gains and lossesReturns from economic activities

Official forms and where it is filed

Frequently asked questions

Do I have to declare trading if I have not withdrawn the money from the broker?

Yes. The gain is attributed to the year you close the trade, not the year you take the money out. A position closed with a profit in 2026 goes into the 2026 Renta even if the balance remains on the platform.

Am I obliged to file the Renta if I have only had losses?

It depends on the rest of your income, but you are only completely exempt if your income for the year does not exceed €1,000 and your capital losses are less than €500. Even if you are not obliged, it is in your interest to declare: the declared loss is the one you can offset in the following four years.

Is the tax report from a foreign broker useful as it comes?

Almost never. It is usually in dollars, with an average price instead of FIFO and without applying the two-month rule. It is the basis for the calculation, but it must be adapted to Spanish rules. Managora does this in its trading tax report: you can see the updated amount on the file.

Can I subtract commissions and the platform subscription?

Purchase and sale commissions, yes: they form part of the cost or reduce the sale amount. Subscriptions, courses or signals do not, unless your trading is an economic activity, as happens with funded accounts.

Can I offset trading losses against my salary?

No. Capital losses go to the savings base and are only offset against other capital gains and, up to 25%, against dividends and interest. Whatever is left over is carried forward four years.

I did not declare trading from previous years, what do I do?

Correct the Renta for each non-prescribed year, which are the last four since the end of each filing deadline: from the 2024 Renta, with a rectifying self-assessment; in the 2023 one and earlier, with a complementary return if it results in a payment or with a rectification request if it results in a refund (for example, to record losses you did not declare). Doing it before Hacienda requires you to is much cheaper than waiting for a tax review (comprobación). Managora prepares and files these corrections for form 100.

We handle the whole procedure for you, from start to finish.

You describe your case in a chat and sign; we file it with the Spanish authorities. Fixed price from €199.00 (21% VAT included), plus the tasa (official fee) where there is one.

See the procedure

Related procedures

The price, the tasa (official fee) and the current deadlines are on each procedure page.

Related guides

Share this guide

If you found it useful, chances are someone you know needs it right now.