How is net salary calculated

Imagine you have a job offer, a tempting new annual gross salary, but what's the monthly net amount? What's the exact salary increase? Imagine being able to compare your current salary with your future one simply by dragging a slider. I bring you the solution:

πŸ’° Net Salary Calculator

If you're like me, to calculate net salary from gross, you'd resort to the first Google result. Constantly scrolling up and down, refreshing the page which, by the way, is barely usable on mobile.

And if you wanted to be precise, you'd create an Excel with the typical tax bracket table and calculate it manually:

State IRPF Brackets

That's it, right? Well, no... to properly calculate the real net salary, there are many more details to consider.

One day I wanted to slay this dragon and understand as best as possible how it's calculated. While researching, I developed this net salary calculator to validate what I was learning.

Basic knowledge first πŸ§‘β€πŸ«

There's a kind of urban legend that says: "If they raise your salary and you change tax brackets, you might end up earning less." I've heard it several times and it perfectly explains how little financial education there is in schools. I guess learning that someone parted the seas and multiplied bread is more important... well, I'm getting off track.

NO.

It's impossible for a salary increase to result in earning less net income. The brackets are cumulative. Example, let's imagine that Paco earns €30,000 gross per year:

The first €12,450 has 19% withholding. What's between €12,450 and €20,200, that is, the next €7,750 has 24% withholding. Finally, the difference between €26,059 and €20,200 => €5,895 has 30% withholding.

The first part of the salary will always have a lower withholding and increases progressively in each bracket. I've tried to show this through graphs in the calculator, try it out.

Explained Brackets

Expenses πŸš—

If you've been reading carefully, you'll have noticed that in the last subtraction I didn't use €30,000 but €26,059. One of the reasons is expenses.

There's a minimum expense of €2,000, all calculations must be made by initially subtracting this value from the gross, in Paco's case, after subtracting expenses we're left with €28,000. But this figure still isn't €26,059, what's missing? Social Security.

Social Security πŸ₯

Besides expenses, another concept to deduct before calculating IRPF is Social Security. This should be easy, it's 6.47% but with a nuance, there's a minimum and maximum. The maximum is reached at €56,646 gross annually, all salaries above that pay the same. The minimum* is €15,120 gross annually. All this data applies to 2024. They've been increasing each year.

Paco has a Social Security payment of €1,941 which if we subtract from €28,000 we already have the figure I used in the previous calculation. Let's name everything.

Taxable Base

Taxable Base = Gross Salary - Expenses - Social Security €26,059 = €30,000 - €2,000 - €1,941

State and Regional IRPF

Now yes, with the taxable base we can calculate the IRPF.

Online calculators usually only show you some IRPF brackets. Those brackets are the state ones and apply to everyone except Basques and Navarrese. What we don't usually take into account is that each autonomous community has its brackets, and they're ALL different. Check the breakdown of IRPF brackets for each autonomous community in Spain in the corresponding tab.

IRPF brackets for each community

The typical State table only applies to non-resident Spaniards, if you reside in Spanish territory, your community's table and the state table are used (with half the percentage in each bracket). Notice in the image how the state percentages are now 9.5%, 12% and 15% instead of 19%, 24% and 30%.

State and Catalan IRPF brackets

I've added the option to see the aggregated brackets, to make it visually easier to see the different brackets that apply to you.

Aggregated State and Catalan IRPF brackets

We could calculate the IRPF but first, let's talk about deductions.

Deductions

You might be familiar with the figure €5,550. It's the deductible minimum. In the most common case, single person without children etc., they have that deductible minimum. To deduct it, brackets are also applied. That is, to know how much we can deduct if we live in Catalonia we have to apply both the state and autonomous community brackets to the figure to be deducted. Example:

€5,550 is in both the first State bracket (up to €12,450) and Catalonia's (up to €12,450), therefore the first bracket rate applies:

  • State 9.5% - €527.25
  • Catalonia 10.5% - €582.75

The total state taxes are reduced by the calculated deduction, same with the autonomous community.

IRPF = IRPF taxable base (brackets) - deductions (brackets)

This is the standard case, deductions increase for each child, for each dependent ancestor, etc. I've included most of these cases in the net salary calculator.

Let's imagine Paco has twins, 2 children under 3 years old. Well, the deductions increase to:

  • State 4.66% - €1,035.5
  • Catalonia 5.2% - €1,144.5

The resulting monthly net salary with 12 payments is €2,007.45, which compared to the salary without children (€1,918.29) results in €89.16 more per month for having two children under 3 years old, not sure if it's enough for diapers πŸ˜„.

I've added this data in the calculator

Deduction Benefit

Keep in mind that I'm assuming Paco makes an individual tax declaration, therefore the deduction is 50%. If he files jointly (only married couples), he gets 100%, double the deduction than individual.

The Formula πŸŽ‰

The final formula for calculating your net salary is as follows:

Net Salary = Gross Salary - Expenses - Social Security - State IRPF - Regional IRPF

With the nuances already mentioned:

  • IRPF and its deductions are calculated on the taxable base and with the corresponding brackets.
  • There's a minimum and maximum for Social Security.

I hope to have clarified a bit how this calculation works, it's important to know this information.

Details like MEI, flexible compensation, Beckham Law, etc. are missing. I'll explain them in future entries.

Sources