Spain: two right answers for the same salary
Ask what tax a Spanish salary pays and there are two correct answers. Your payslip withholds a retención, worked out by the tax agency's own published algorithm on a single national scale that takes no account of where you live. Your annual return then charges the real thing: the state scale plus your autonomous community's own scale. The two are deliberately different, and the gap comes back as a refund or a bill each spring. This calculator shows the annual liability, because that is what the year actually costs, and quotes the retención beside it so you can match your payslip.
The community matters. Across the fifteen communities this calculator models, the top regional rate runs from Madrid's 20.50% to Comunitat Valenciana's 29.50%, with Cataluña at 25.50% in between, all on top of the same state scale, so the same salary can differ by hundreds of euro depending on the address. Four territories, Alava, Bizkaia, Gipuzkoa and Navarra, are outside the system entirely: they levy their own IRPF under a separate agreement, and are not modelled here.
Two mechanisms surprise people. The minimo personal y familiar is not subtracted from your income: the scale is applied to your income, applied again to the minimum, and the second figure taken off the first, so the relief is worth the same to a cleaner and to a chief executive. And your contribution group puts a floor under your social security base, so a graduate in group 1 on a low salary contributes on more than they actually earn.
Worked example: EUR 30,000 in Madrid, single, permanent contract
Social security €1,950: 4.70% common contingencies, 1.55% unemployment, 0.10% training and 0.15% for the intergenerational equity mechanism.
After the €2,000 fixed expenses allowance, the base is €26,050. The scales give €2,463 to the state and €2,169.58 to Madrid, each already net of the minimum.
Take-home: €23,417.42 a year, €1,951.45 a month. Your payslip will show a retención of €4,926 at 16.42%, a little more than the €4,632.58 finally due, so expect a refund.