arfin
Back to blog
taxestax returnDEGIROTrade RepublicSpainfiscal

How to Declare Your Broker Investments on Spanish Taxes (Step-by-Step Guide)

A practical guide to declaring capital gains, dividends, and trades from DEGIRO, Trade Republic, and Interactive Brokers on your Spanish tax return.

March 10, 202621 min

This article contains affiliate links. If you open an account through our links, we may receive a commission at no extra cost to you. This helps us keep Arfin free.

This article is for informational purposes only and does not constitute tax advice. Consult a qualified tax advisor for your specific situation.

Tax season in Spain runs from April to June, and if you invest through brokers like DEGIRO, Trade Republic, or Interactive Brokers, you already know the feeling: you open Hacienda's draft return (borrador) and your trades are nowhere to be found. Or worse, some data appears but the numbers don't match.

Here's the reality: the Spanish tax authority (Agencia Tributaria) doesn't automatically receive your data from foreign brokers. It's your responsibility to correctly declare every gain, every dividend, and every interest payment. Get it wrong and you might overpay — or underpay, which comes with consequences.

But it doesn't have to be overwhelming. In this guide we'll walk through everything you need to know to declare your broker investments on the Spanish tax return: from understanding the tax brackets to knowing exactly which boxes (casillas) to fill in for each broker.


How Investments Are Taxed in Spain

Before diving into broker-specific details, you need to understand how investment income is taxed in Spain. All investment income falls under the savings base (base del ahorro) of your tax return, which has its own progressive brackets.

Savings Income Tax Brackets (2025)

| Income bracket | Tax rate | |---|---| | Up to 6,000 EUR | 19% | | 6,001 to 50,000 EUR | 21% | | 50,001 to 200,000 EUR | 23% | | 200,001 to 300,000 EUR | 27% | | Over 300,000 EUR | 28% |

These brackets are progressive, meaning you don't pay 21% on everything if you earn 10,000 EUR. You pay 19% on the first 6,000 EUR and 21% on the remaining 4,000 EUR.

Types of Savings Income

Within the savings base, there are two main categories:

Offsetting Losses

One of the most important tax advantages is that you can offset losses against gains. If you sold a position at a loss, that loss reduces your taxable base. The rules are:

Watch out for the anti-avoidance rule: if you sell an asset at a loss and buy the same asset (or a substantially identical one) within two months before or after the sale, you cannot deduct that loss. This is Spain's equivalent of the "wash sale rule." Keep this in mind before doing any tax-loss harvesting.

Savings Base vs General Base

Don't confuse the savings base with the general base (base general). The general base includes your salary, self-employment income, rental income, etc. Investment income always goes into the savings base (with very few exceptions for atypical financial products).


What Exactly You Need to Declare

Let's break down the four main types of investment income you must include in your tax return:

1. Capital Gains and Losses from Asset Sales

Every time you sell a stock, ETF, fund, or any other financial instrument, you must declare the capital gain or loss. To calculate it you need:

If you trade in currencies other than the euro (for example, US stocks in dollars), you must convert both the purchase price and sale price to euros using the exchange rate on the date of each transaction. This can generate additional exchange rate gains or losses.

2. Dividends

Dividends you receive from your stocks or distributing ETFs are classified as investment income (rendimientos del capital mobiliario). You must declare the gross amount of the dividend in euros.

If the dividend comes from a foreign company, taxes have most likely already been withheld in the country of origin. For example:

These foreign withholdings are deductible on your Spanish tax return (more on this in the common mistakes section).

3. Foreign Withholding on Dividends

As just mentioned, when you receive dividends from foreign companies, the country of origin typically withholds a percentage. Spain has double taxation treaties with most countries, allowing you to deduct that foreign withholding from what you owe in Spain.

The maximum deduction is the lesser of:

In practice, for most retail investors, you can deduct the full foreign withholding (up to the treaty limit, which is usually 15%). If more than 15% was withheld (as sometimes happens in Germany or France), you can request a refund of the excess from the source country, although the process is complex.

4. Interest from Accounts and Deposits

If you have a savings account (like Trade Republic's) or a fixed-term deposit, the interest earned is investment income and must be declared.

In Trade Republic's case, savings account interest is paid monthly and appears on your annual statement. Germany does not withhold taxes on this interest if you've provided your Spanish tax residency certificate. If you haven't, they may withhold 26.375%, and you'll need to claim a refund.


DEGIRO: Step by Step

DEGIRO is one of the most popular brokers among Spanish investors thanks to its low commissions. It's registered in the Netherlands and regulated by the Dutch AFM. This means your data won't automatically appear on Hacienda's draft tax return.

Step 1: Download the Necessary Reports

Log into your DEGIRO account and go to the Reports section. You'll need to download:

  1. Annual Report: summarizes all your positions, realized gains and losses, and dividends received during the tax year. This is your primary document.
  2. Transaction History: details every buy and sell transaction. Useful for verifying the Annual Report's calculations.
  3. Dividend Report: if available as a separate document, download it too. It details each dividend received, the withholding at source, and the net amount.

Tip: download the reports as soon as they're available (usually in January or February of the following year). Don't wait until the tax filing period starts.

Step 2: Identify Capital Gains and Losses

With the annual report in hand, make a list of all the sell transactions you made during the tax year. For each one you need:

Remember to apply the FIFO method if you purchased the same asset on multiple occasions.

If you traded assets denominated in currencies other than euros (US stocks, for example), you must convert amounts to euros at the ECB exchange rate on the date of each transaction.

Step 3: Fill in the Corresponding Boxes

On the Spanish tax return (Modelo 100), capital gains and losses from asset sales go in boxes 0328 to 0342 (these may vary slightly from year to year — always check the current year's manual).

For each transaction or group of transactions:

For dividends, these go in the investment income boxes, typically box 0029 and following. You must indicate:

Step 4: Apply the Double Taxation Deduction

The withholdings that DEGIRO applied at source (for example, 15% Dutch withholding on Dutch company dividends, or 15% US withholding if you signed the W-8BEN) are declared in the international double taxation deduction section (boxes 0588 and following).

Common Issues with DEGIRO


Trade Republic: Step by Step

Trade Republic is a German broker regulated by BaFin. Its popularity has surged in Spain thanks to its savings account and free savings plans.

Step 1: Access Your Tax Documentation

In the Trade Republic app, go to Profile > Documents. There you'll find:

  1. Annual Tax Certificate (Jahressteuerbescheinigung): the main document. It includes a summary of all your gains, losses, dividends, and interest for the year.
  2. Account Statements: showing each movement, including savings account interest payments.
  3. Dividend Settlement Documents: details of each dividend payment received.

Important note: Trade Republic issues these documents according to German tax regulations. The concepts may not match exactly with Spanish tax categories. You'll need to "translate" the information.

Step 2: Declare Capital Gains and Losses

The process is similar to DEGIRO:

  1. Identify all sell transactions for the tax year.
  2. Calculate the gain or loss for each one (sale price - acquisition price, both including commissions).
  3. Apply the FIFO method.
  4. Fill in boxes 0328-0334 on Modelo 100.

Trade Republic charges 1 EUR per trade. This euro is part of the acquisition or sale costs, as applicable.

Step 3: Declare Dividends

Dividends received through Trade Republic go in the investment income boxes (box 0029 and following).

German withholding: Germany withholds 26.375% on dividends (25% Kapitalertragsteuer + 5.5% Solidaritatszuschlag on top). However, the double taxation treaty between Spain and Germany limits the withholding to 15%. In practice:

Alternatively, if you provided your tax residency certificate to Trade Republic before the dividend payments, the withholding may have already been limited to the 15% treaty rate.

Step 4: Declare Savings Account Interest

This is a point many investors forget. The interest your Trade Republic savings account generates is investment income and must be declared.

Common Issues with Trade Republic


Interactive Brokers: Step by Step

Interactive Brokers is the go-to broker for more advanced investors. Its Irish headquarters (for European clients) makes it a foreign broker for all Spanish tax purposes.

Step 1: Generate Your Annual Report

Interactive Brokers offers the most comprehensive tax reports of the three brokers. Go to Performance & Reports > Statements > Activity:

  1. Annual Statement: the most complete report, covering all trades, dividends, interest, commissions, and currency movements.
  2. Tax Report: some years IBKR generates specific tax reports. Check if one is available.
  3. Dividend Report: details of each dividend payment with source withholdings.

Select the full tax year period (January 1 to December 31) and generate the report in PDF or CSV format.

Step 2: Organize Capital Gains and Losses

With IBKR, complexity increases for several reasons:

For stocks and ETFs (the most common case):

  1. Download the annual statement.
  2. Locate the "Realized P&L" section.
  3. Verify the calculation method matches FIFO (IBKR allows different methods internally, but for Spanish tax purposes you must use FIFO).
  4. Convert all gains and losses to euros.

Step 3: Declare Dividends

IBKR details each dividend received, including:

You must convert the gross amount to euros and declare it in the corresponding boxes. Source withholdings are deducted as double taxation relief.

Step 4: The Multi-Currency Challenge

This is probably the most complex aspect of filing taxes with Interactive Brokers. When you have a balance in US dollars and convert it to euros (or vice versa), that conversion can generate a capital gain or loss from exchange rate fluctuation.

Similarly, if you buy stocks in dollars and sell them months later, the gain or loss includes two components:

  1. The change in the stock price.
  2. The change in the EUR/USD exchange rate between the purchase date and the sale date.

Both components form part of the total capital gain or loss and must be declared together.

Practical tip: use the exchange rate published by the ECB for each date. IBKR may use slightly different rates (their own market rate), but the ECB is the official reference for Hacienda.

Common Issues with Interactive Brokers


Common Mistakes to Avoid

After years of helping investors understand their portfolios, these are the mistakes we see again and again:

1. Not Claiming Double Taxation Relief

This is the most costly mistake. If you receive dividends from foreign companies and taxes were withheld at source, you have the right to deduct that withholding on your Spanish return. Not doing so means paying taxes twice on the same income.

To apply the deduction, you need to:

2. Forgetting Exchange Rate Gains

If you bought US stocks when EUR/USD was at 1.20 and sold them when it was at 1.05, you've made an additional exchange rate gain on top of any stock price gain. Many investors only look at the stock price and forget the currency component.

3. Not Correctly Applying the FIFO Method

If you bought 100 shares of Apple at three different times:

And you sell 40 shares in 2025, FIFO dictates that you sell the first 30 (from January 2024) and 10 of the second batch (from June 2024). You cannot choose which ones to sell for tax optimization.

4. Not Filing Modelo 720

If on December 31 you have more than 50,000 EUR in securities held at a foreign broker (DEGIRO, Trade Republic, Interactive Brokers — they all count), you are required to file Modelo 720. Failure to file can result in penalties, although the severity has been reduced following the CJEU ruling of 2022.

5. Confusing FIFO with Weighted Average Cost

In Spain, the official method for stocks and ETFs is FIFO, not weighted average cost. However, for investment fund units (participaciones en fondos de inversion), the weighted average cost method is used. Don't mix up the two methods.

6. Not Declaring Savings Account Interest

With the popularity of savings accounts (Trade Republic, brokers paying interest on cash), many investors forget that this interest is investment income and must be declared, no matter how small the amount.

7. Ignoring the Two-Month Rule

If you sell an asset at a loss and buy the same asset (or a substantially identical one) within two months before or after the sale, you cannot offset that loss. Many investors attempt tax-loss harvesting without considering this rule and run into problems later.


Modelo 720 and Modelo D-6

Modelo 720: Declaration of Assets Abroad

Modelo 720 is an informational declaration (it doesn't involve a payment) that must be filed by Spanish tax residents who hold assets abroad above certain thresholds.

Who must file it:

Any Spanish tax resident who, on December 31, holds abroad:

Each of these three categories has its own independent 50,000 EUR threshold. This means you could have 40,000 EUR in a foreign bank account and 45,000 EUR in securities at a foreign broker without being required to file Modelo 720 (because neither category individually exceeds 50,000 EUR).

When to file:

Between January 1 and March 31 of the year following the tax year. That is, for assets held on December 31, 2025, the deadline runs from January to March 2026.

Filing in subsequent years:

You only need to re-file Modelo 720 if the value in any category has increased by more than 20,000 EUR compared to the last declaration filed.

Penalties:

Following the Court of Justice of the EU ruling in January 2022, Spain had to reform its penalty regime. The disproportionate penalties (fines of 5,000 EUR per undeclared data item) were eliminated. Now the general penalties under the General Tax Law apply, which are much more moderate. However, filing remains mandatory.

Which brokers count as "foreign":

Modelo D-6: Declaration of Spanish-Resident Investments in Foreign Securities

Modelo D-6 is another informational declaration, but this one is filed with the Ministry of Economy (not with Hacienda). It's mandatory for Spanish residents who hold securities traded on foreign markets, deposited at entities located outside Spain.

Deadline: during the month of January of the following year.

Who must file it: any resident with foreign securities, with no minimum threshold. That means if you have even a single share at DEGIRO, you technically should file it.

In practice, this obligation is less well-known and compliance is more lax, but it's important to know it exists.


Tools That Make Your Life Easier

Declaring investment income doesn't have to be a nightmare. There are tools that can help enormously:

TaxDown

TaxDown is a Spanish tax filing platform that guides investors step by step. Their investor plan includes:

It's especially useful if you don't want to deal with the boxes one by one. The platform asks you questions in plain language and fills in the return for you.

Specialized Tax Advisors

If your situation is complex (you trade options, have accounts in many countries, do frequent trading), it may be worth hiring a tax advisor specializing in investments. The typical cost is between 150 and 500 EUR depending on complexity, but it can save you much more in errors and penalties.

Look for advisors who:

Arfin for Cost Basis Tracking

One of the biggest difficulties when filing is knowing exactly how much you paid for each position and when you bought it. This gets complicated when:

Arfin helps you maintain a consolidated record of all your positions, with:

It doesn't replace a tax advisor or a filing tool like TaxDown, but it's the perfect complement for keeping your data organized year-round — not just in April.


Conclusion: Prepare Year-Round, Not in April

The best advice we can give you is this: don't wait until the tax filing period to organize your tax data. If you accumulate the information throughout the year, the filing process becomes much simpler.

Here's an action plan:

  1. Right now: download the annual reports from your brokers if you haven't already.
  2. Throughout the year: record your transactions in a tool like Arfin to keep your cost basis always up to date.
  3. In January-March: file Modelo 720 and Modelo D-6 if they apply to you.
  4. In April-June: file your income tax return with all the information organized.

If you want to simplify the process, TaxDown is an excellent option for the filing itself, and Arfin helps you stay on top of your portfolio all year long.

Try TaxDown for your tax return | Sign up for Arfin to track your portfolio


Remember: this article is for guidance only and does not replace professional tax advice. Tax regulations change frequently, and your personal situation may require specific treatment. Always consult a qualified tax advisor.

Track all your wealth in one place

Join the waitlist