Confidentiality

Anonymising personal data: what it is, techniques with examples and the process the Spanish DPA recommends

Removing the name is not enough to make data anonymous. Here is what anonymisation means under the GDPR, its techniques with an example of each, the process the Spanish data protection authority recommends and what changes when what you anonymise is a legal document.

14 November 2026 · 11 min read · By Guillermo Azcona

The anonymisation of personal data is processing that makes data no longer able to identify anyone, directly or indirectly, by the means anyone could reasonably use. Under recital 26 of the GDPR, anonymous information falls outside the Regulation; pseudonymised data does not. The techniques form two families, randomisation and generalisation, almost always applied after removing the direct identifiers, and the Spanish data protection authority (AEPD) asks you to assess the re-identification risk before treating anything as anonymous.

What anonymising personal data means under the GDPR

Anonymising personal data is processing that turns data about people into information that no longer allows them to be identified. The GDPR does not define it in its articles; its recital 26 sets the test: to determine whether someone is identifiable, “account should be taken of all the means reasonably likely to be used, such as singling out, either by the controller or by another person to identify the natural person directly or indirectly”, taking into account costs, time and technology. It adds that the principles of data protection should not apply to “personal data rendered anonymous in such a manner that the data subject is not or no longer identifiable”.

The Article 29 Working Party summed it up in its Opinion 05/2014 on Anonymisation Techniques: “anonymisation results from processing personal data in order to irreversibly prevent identification”.

A direct identifier “is specific information that references to an individual, such as name or an identification number”, according to the AEPD and the European Data Protection Supervisor (EDPS) in 10 misunderstandings related to anonymisation (2021). A quasi-identifier does not identify on its own, but it does in combination with others: the AEPD lists gender, marital status, postcode, significant dates and profession. The AEPD and EDPS paper recalls that in 2006 a movie-streaming service published 10 million movie rankings made by 500,000 customers as anonymous, and a little knowledge about a subscriber was enough to find their record.

If additional information (a correspondence table, a key) lets you get back to the person, the data is pseudonymised, and recital 26 still treats it as “information on an identifiable natural person”. The difference, with examples, is in anonymisation vs pseudonymisation.

Data anonymisation techniques, with an example of each

The most common anonymisation techniques are suppression, masking, generalisation, noise, k-anonymity and aggregation. To see them at work, start from this table of clients of an employment law firm (the data is invented):

PostcodeAgeMatterAmount claimed
Ana Ruiz Gil3100834Dismissal18,400 euros
Luis Sanz Mora3100638Dismissal9,750 euros
Rosa Lana Pérez3150041Wage claim4,200 euros
Iker Goñi Ayala3150046Wage claim6,900 euros

The name is the direct identifier; the postcode and the age are quasi-identifiers. This is Ana's row under each technique:

What it doesAna's row
SuppressionRemoves the data item, or the whole row31008 · 34 · Dismissal · 18,400 euros
MaskingCovers the identifier with the same filler for everyone[NAME] · 31008 · 34 · Dismissal · 18,400 euros
GeneralisationRanges and truncated codes310** · 30 to 39 · Dismissal · 18,400 euros
Randomisation or noiseShifts the values by a random margin31008 · 34 · Dismissal · 18,900 euros
k-anonymity (k = 2)Each combination of quasi-identifiers appears at least k timesAna and Luis share “310** · 30 to 39”; Rosa and Iker, “31500 · 40 to 49”
AggregationTotals or averages instead of rows2 dismissals, with an average claim of 14,075 euros

Suppression and masking

Suppression removes what is not needed: the AEPD lists, among others, names, date of birth, phone number, ID number, postal address, bank accounts and IP address. Masking finds and covers the direct identifiers, with a limit that the AEPD and the European Data Protection Supervisor point out: “While direct identifiers are somewhat trivial to find, indirect identifiers, on the other side, are not always obvious”. And if instead of the same filler for everyone you use one tag per person ([PERSONA 1], [PERSONA 2]) and keep a record of who each one is, that is pseudonymising.

Generalisation and k-anonymity

Generalisation changes the scale, using “a region rather than a city, a month rather than a week” (Opinion 05/2014). The AEPD's technical note on k-anonymity (2019) measures the result: if every combination of quasi-identifiers is shared by at least k people, the probability of identifying one of them from those values “is at most 1/k” (with k = 2, 50%). Its weak point, according to the same note: if the whole group shares a sensitive value, it is enough to know that someone is in the group. Ana and Luis are the two dismissals: anyone who knows that Ana is a client of the firm, is 30 to 39 and lives in a 310** postcode knows she was dismissed.

Noise, aggregation, encryption and hashing

Noise makes values less accurate without changing their distribution (Opinion 05/2014 gives the example of a height published “accurate to only +-10cm”), and permutation swaps them between rows; neither anonymises on its own. Aggregation hands over statistics instead of rows, and the opinion treats it as anonymous when the controller deletes the raw data. Encryption and hashing, on the other hand, can be reversed with the key or recalculated: “Encryption is not an anonymisation technique, but it can be a powerful pseudonymisation tool” (AEPD and European Data Protection Supervisor).

Which technique protects against what: singling out, linkability and inference

An effective anonymisation prevents three things, according to Opinion 05/2014: singling out (isolating the records that identify an individual), linkability (linking two records about the same person, in one database or in two) and inference (deducing, with significant probability, one value from others). Its Table 6 sums up which risk each technique leaves open:

Is singling out still a risk?Is linkability still a risk?Is inference still a risk?
PseudonymisationYesYesYes
Noise additionYesMay notMay not
SubstitutionYesYesMay not
Aggregation or K-anonymityNoYesYes
L-diversityNoYesMay not
Differential privacyMay notMay notMay not
Hashing/TokenizationYesYesMay not

No row says “No” in all three columns: that is why the opinion asks for a case-by-case decision and a combination of techniques.

On 7 July 2026 the European Data Protection Board (EDPB) adopted draft Guidelines 02/2026 on Anonymisation, which update that opinion. They keep three criteria under new names (“No Record Isolation, No Linkage and No Inference”), assess anonymity from the perspective of each relevant entity, whether or not the original data is deleted, and ask for the likelihood of identifying someone to be “insignificant in reality”, not zero. The public consultation closed on 30 October 2026 and, as of 14 November, version 1.0 is still the one published.

The anonymisation process according to the AEPD, step by step

The AEPD sets out a protocol in phases in its Orientaciones y garantías en los procedimientos de anonimización de datos personales (guidance and safeguards for personal data anonymisation, in Spanish), a 2016 guide that it publishes marked «En revisión» (under review) and presents as guidance, not as a closed scheme. The quotes are our translation:

  1. A team, in writing. The controller, the data protection officer and teams for risk, anonymisation and security, in numbers “proportional to the volume of the data processing and to the complexity of the anonymisation process”. Roles can be combined, but “it is essential that there is a document defining the working team”.
  2. A re-identification risk assessment, with its acceptable threshold, starting from the fact that “no anonymisation technique can guarantee in absolute terms that re-identification is impossible”. It is reviewed periodically, because the risk grows over time.
  3. Purpose and recipient: restricted use, with confidentiality agreements, or open data.
  4. Pre-anonymisation: classifying direct identifiers, indirect identifiers and specially protected data. The guide warns how hard it is to anonymise “voice recordings, image recordings or biometric and/or genetic information”.
  5. Removing variables that are not needed for the purpose.
  6. Techniques and a pilot “with a small sample of test data (not real data)”.
  7. Anonymisation for each recipient, staff training, safeguards and periodic audits.
  8. Documentation. “The applicable anonymisation policy must be documented and accessible to the staff involved in processing anonymised data”. The EDPB draft also asks for the process and its testing to be documented.

Whether your case needs a data protection impact assessment, or which legal basis covers it, is a question for the data protection officer or for a lawyer.

Anonymising a database or a text document

A database and a text document are anonymised in different ways: the guidance of the AEPD and of the Article 29 Working Party is designed for tables, and a brief, a judgment or a set of minutes is free text. The AEPD and the European Data Protection Supervisor define a dataset as “a structured collection of data”, and Opinion 05/2014 makes clear that its examples “will relate to tables”.

Database or spreadsheetBrief, judgment or minutes
Where the data isIn known columnsIn any sentence, mixed with the narrative
Techniques that fitSuppression, generalisation, noise, k-anonymity and aggregationTags or fillers for the identifiers, and generalising the details by hand
How you check itCounting how many rows share each combination of quasi-identifiersReading it all: there are no rows to count

An example from a brief (invented, translated from Spanish):

“Ms Marta Ibáñez Soto, DNI 12345678Z, owner of the only pharmacy in Valdecierzo, was dismissed on 3 March 2026, after four months of sick leave for a herniated disc.”

With tags it reads “Ms [PERSONA 1], DNI [DNI 1], owner of the only pharmacy in Valdecierzo…”, and anyone in the village still recognises her: profession, “the only pharmacy” and the place are quasi-identifiers, and the herniated disc is health data (Article 9 of the GDPR). You have to generalise by hand: “a pharmacist in a small municipality, dismissed in March 2026 after sick leave”. The judgments that CENDOJ, the documentation centre of the Spanish judiciary, publishes come with the names replaced and the other personal data of the individuals who are parties hidden, as we explain in the CENDOJ case law search engine. The transcript of a hearing raises the same problem, and the original recording still identifies people by their voice.

With ablalo you anonymise on your computer, without uploading anything, pasted text, a Word file (.docx), a PDF (also scanned) or a .txt file in Spanish: it replaces names, DNI and NIE, NIG, IBAN, bar numbers, addresses and other identifiers with tags such as [PERSONA 1] and flags anything doubtful for you to review. It leaves courts, laws, cities, amounts and dates (except the date of birth) visible. It is designed for documents: it does not generalise, it does not calculate k-anonymity and it is not for spreadsheets or databases.

Limits: what no technique or tool solves on its own

No technique guarantees 100% anonymity, and a document with tags is not anonymous just because it has them:

In short

Anonymising personal data turns data about people into information that no longer allows them to be identified by the means anyone could reasonably use (recital 26 of the GDPR); if additional information leads back to the person, it is pseudonymisation and the GDPR still applies. The techniques are combined because none of them prevents singling out, linkage and inference all at once, and the AEPD proposes doing it with a team, a re-identification risk assessment, a pilot and documentation. In a legal document, replacing names with tags is the first step: then you have to read it all looking for whatever still identifies someone.

Sources: Regulation (EU) 2016/679 (GDPR), recital 26 and Article 4(5), on EUR-Lex; Article 29 Working Party, Opinion 05/2014 on Anonymisation Techniques, 10 April 2014; AEPD, Orientaciones y garantías en los procedimientos de anonimización de datos personales (in Spanish), 2016; AEPD, K-anonymity as a privacy measure, 2019; AEPD and European Data Protection Supervisor, 10 misunderstandings related to anonymisation, 2021; European Data Protection Board, Guidelines 02/2026 on Anonymisation, version 1.0 for public consultation, 7 July 2026. Checked on 14 November 2026.

Frequently asked questions

What is the anonymisation of personal data?

It is processing that turns personal data into information that no longer allows the person to be identified, directly or indirectly, by the means anyone could reasonably use. Under recital 26 of the GDPR, the principles of data protection do not apply to anonymous information.

What does data anonymisation involve and what is it for?

It involves removing or transforming the direct identifiers and the quasi-identifiers until there is no way back to the person. It lets you use or share data (studies, statistics, open data) with less risk for the people concerned, although a residual risk of re-identification always remains and has to be assessed.

What data anonymisation techniques are there?

Opinion 05/2014 of the Article 29 Working Party groups them into randomisation (noise addition, permutation and differential privacy) and generalisation (aggregation, k-anonymity, l-diversity and t-closeness). In practice they are combined with suppressing or masking the direct identifiers. Encryption and hashing pseudonymise; they do not anonymise.

What data anonymisation tools are there?

For tables and databases, the AEPD's technical note on k-anonymity cites three open source tools: ARX, the UT Dallas anonymisation tool and Amnesia. For text documents there are anonymisers that replace identifiers with tags, such as the Anonymize section of ablalo. In every case, the result has to be reviewed.

How do you anonymise data in documents?

You find the direct identifiers (names, ID numbers, addresses, bank accounts) and replace them with tags or fillers; then you read the whole document to generalise the details that still identify someone, such as the profession, the place or health data, and you clean the file properties. If you keep the table that lets you put the names back, the result is pseudonymised, not anonymised.

What law governs data anonymisation?

The GDPR has no article devoted to it: it deals with it in recital 26, which leaves anonymous information outside its principles, and it defines pseudonymisation in Article 4(5). Opinion 05/2014 notes that EU law imposes no particular technique (“there is no prescriptive standard in EU legislation”). In Spain, the AEPD publishes practical guidance, and the European Data Protection Board is preparing guidelines (draft 02/2026).

Remove your client's details before sharing a document

ablalo replaces names, DNI and NIE, NIG, IBAN, bar numbers and addresses in a text, a Word file or a PDF (also scanned) with tags such as [PERSONA 1], on your computer, and puts the names back when you need them. It is built for documents in Spanish. It does not hide health or trade union membership data: review it before sending. 14-day trial, no card.

See how it works

No card · Windows and Mac · Spanish speech recognition

← Back to the blog