Sources and terms
Everything comes from public, official data. Here you will find, first in a nutshell and then in detail, where each figure comes from, what it means, how it is calculated, what is left out and the legal terms.
In a nutshell
- All figures are official. They come from public bodies (Eurostat, the Spanish Ministry of Finance, the Public Procurement Platform, the OECD) and hucha only organises and explains them. It does not make up or estimate anything, except your receipt, which is an approximate calculation and says so.
- They update themselves every day. If a source fails, the site keeps the latest good data.
- hucha is not an official website and does not belong to any party, administration or company. It gives no opinions: it shows figures and compares them by the same yardstick.
- It may contain mistakes. If you are going to make a decision, check the official source, which is always linked. And if you see something wrong, let us know.
- It keeps nothing of yours: no cookies, no accounts, and your salary never leaves your device.
Words used on this site
- Public spending
- Everything that central government, the autonomous communities, local councils and Social Security spend together in a year.
- GDP (PIB in Spanish)
- Everything a country produces in a year. Saying that spending is 45% of GDP makes it possible to compare countries of different sizes.
- Provisional
- Data for the latest year, which may still be revised. It usually changes little.
- Budget (appropriations)
- What the State is authorised to spend in the year. Final appropriations include the changes approved since January.
- Spent (recognised obligations)
- What the State already has to pay because the work has been done or the entitlement recognised. It is almost always paid within a few days.
- Rolled over
- If no new budget is approved, the previous year’s remains in force. The Spanish Constitution says so (article 134.4).
- Tendered and awarded
- Tendered is the price at which an administration puts a contract out; awarded is the price offered by the company that wins it. It is usually lower.
- Framework agreement
- A contract that sets a maximum price and a set of companies for future purchases. Its amount is a ceiling, not spending, so hucha does not add it up.
- Grant
- Public money given to a company, organisation or person for a specific purpose, which does not have to be repaid.
- Official development assistance
- Spanish public money to improve lives in other countries: health, water, emergencies… The OECD counts it with the same rules for every country.
Public spending
It comes from Eurostat, table gov_10a_exp: general government expenditure by function under the United Nations COFOG classification. For Spain it is compiled by the State Comptroller General (IGAE) and sent to Eurostat, which publishes it on the same basis for every EU country.
It is spending actually made (national accounts), not what was budgeted. It comes with a delay: a year’s data are published early in the year after next, and the latest year is marked as provisional. The site checks itself every day and picks up new data as soon as it is out.
Within each item, “What it is spent on” uses the second level of the same classification (hospitals, medicines, university, development aid…), and “How it is spent” the national accounts transactions in the same table: salaries (D1), purchases (P2), payments to people (D62), services paid to companies for citizens (D632), investment (P5), subsidies (D3), interest (D4), transfers (D7) and investment grants (D9). Anything that fits none goes to “Other”.
Population is Spain’s annual average, from table demo_gind of Eurostat.
How the items are grouped
Each item brings together COFOG functions. Together they cover 100% of spending, without counting anything twice.
| Item | COFOG functions |
|---|---|
| Retirement and survivors’ pensions | 1002 Old age + 1003 Survivors |
| Healthcare | 07 Health |
| Education | 09 Education |
| Sick leave, disability, family and other benefits | 10 Social protection, minus 1002 Old age, 1003 Survivors, 1005 Unemployment |
| Running the administrations | 01 General public services, minus 0107 Public debt transactions |
| Jobs, business, farming and energy | 04 Economic affairs, minus 0405 Transport |
| Interest on debt | 0107 Public debt transactions |
| Roads, railways and transport | 0405 Transport |
| Unemployment | 1005 Unemployment |
| Police, justice and prisons | 03 Public order and safety |
| Culture, sport and religion | 08 Recreation, culture and religion |
| Environment and waste | 05 Environmental protection |
| Defence | 02 Defence |
| Housing, urban planning and water | 06 Housing and community amenities |
The budget and what is spent
It comes from the State Comptroller General (IGAE), which publishes every month how much of the central government expenditure budget has been executed, accumulated since January. Its tables by chapter, by section (ministry), by spending policy and by programme are used.
Budget means final appropriations: what was approved plus the changes made during the year. Spent means net recognised obligations. The headline figures are non-financial operations (chapters 1 to 7). The comparison is with the same month of the previous year because spending is not spread evenly across the year.
It only covers central government: not Social Security, the autonomous communities or local councils. The site checks every day for a new month.
The Lens
- Contracts: those awarded for one million euros or more (excluding VAT) on the Public Sector Procurement Platform, including those from regional and local platforms that feed into it. Its open data are read every day and accumulated. The topic (rail, healthcare…) and whether it is works, maintenance or a purchase come from the contract’s official code (CPV) and its title.
- Grants: those of one million euros or more awarded in the last 12 months, from the National Grants Database.
- Aid to other countries: Spain’s official development assistance disbursements by country, from the OECD, in millions of US dollars.
Individuals (self-employed people, private persons) never appear by name.
How your receipt is calculated
It estimates what you pay per year as a permanent employee with no children or special circumstances:
- IRPF: using the Spanish Tax Agency withholding algorithm for 2026: employment income reduction, €2,000 of other expenses, a personal allowance of €5,550 and the general scale. Nothing is paid up to the minimum wage. Your actual tax return may differ because of regional deductions, children, rent or pension plans.
- Social Security: 6.50% of salary up to the maximum contribution base (common contingencies, unemployment, vocational training and MEI), plus the solidarity contribution above it, under the 2026 contributions order (Orden PJC/297/2026 of 30 March, published in the BOE).
- Your employer, if you turn the option on: a further 30.65% up to the maximum base. Workplace accident insurance is not included, as it depends on the activity.
What you pay is split across the items in the same proportion as public spending that year. It is one way of looking at it: the money in the piggy bank is shared and cannot be traced euro by euro.
Not included: VAT and excise duties (fuel, tobacco, alcohol, electricity), which you pay when you buy; nor property tax (IBI) or other local taxes. And since administrations spend more than they collect, part of spending is paid for with debt.
Privacy
No cookies, no ads and no accounts. Your salary never leaves your browser: the calculation is done on your device. Visits are counted with GoatCounter, which does not store personal data.
In the Lens, when the winner of a contract or the recipient of a grant is an individual (self-employed or a private person), their name is not shown: it appears as “Persona física” (individual) or is not included.
Spotted a mistake?
If a figure does not add up, a contract is misclassified or something is missing, report it on GitHub, ideally with a link to the official source. It will be reviewed and, if it needs fixing, fixed for everyone. Reports are public: do not include personal data.
Legal notice
The same as above, stated precisely. In case of discrepancy, the Spanish version prevails.
Who is behind it
hucha is a personal project by Bendi (github.com/serbenda), published at hucha.bendi.dev. For any communication, including about personal data, you can write via GitHub.
What it is and is not
hucha has a purely informative and educational purpose. It is not an official publication, it is not linked to any public administration, political party, trade union or company, and it receives no public funding. Its contents do not constitute tax, legal, financial or any other kind of advice. The “your receipt” calculation is a rough estimate using general rules and does not replace a tax return or any official calculation.
Data sources and re-use
The data come from public sources and are re-used under their terms, always citing the source, without altering its meaning and with the date of the latest update:
- Eurostat, under its copyright and re-use policy.
- State Comptroller General (IGAE), Public Sector Procurement Platform and National Grants Database, under Spanish Law 37/2007 on the re-use of public sector information.
- OECD, under its terms and conditions.
The sources take no part in hucha and do not endorse its contents. Grouping, ordering or calculating from their data (items, percentages, euros per person, totals excluding framework agreements) is hucha’s own work, and the site explains in each case how it is done.
Accuracy and liability
Every effort is made to keep the information accurate and up to date, but it may contain errors, omissions or delays, its own or the sources’. hucha does not guarantee the accuracy or completeness of the data and accepts no liability for decisions made on the basis of them. For any use with consequences, check the linked official source.
Personal data
hucha collects no personal data from visitors: there are no forms, accounts or cookies, and the salary entered in the receipt is processed only on the device itself. Visits are counted with GoatCounter in aggregate, without cookies and without storing the IP address.
Contracts and grants come from public registers whose publication is required by law ( Law 9/2017 on Public Sector Contracts and Law 38/2003 on Grants). Even so, for data minimisation, hucha does not show the names of individuals (self-employed or private persons): in contracts they appear as “Persona física” and grants to individuals are not included. If you think personal data appears that should not, write via GitHub (without putting the data in the message, which is public) and it will be removed. You can also complain to the Spanish Data Protection Agency (AEPD).
Intellectual property
hucha’s code, design, texts and charts belong to its author, all rights reserved (see the licence). The data belong to their sources. Names of public bodies and companies are used only to identify them.
Links
The site links to third-party pages (official sources, contract files, grant calls) that it does not control and for whose content it is not responsible.
Governing law
This notice is governed by Spanish law.