How to anonymize HR and employee data
For pay reviews, consultants, surveys and AI tools
HR spreadsheets travel: a pay review for a consultant, headcount numbers for the board, a test file for a new HR system, a survey export for analysis. They also hold some of the most sensitive data a company has. Remove what identifies people, and keep what the analysis needs.
Why HR data needs extra care
- Health, trade union membership, ethnic origin and some other details are special categories of personal data (GDPR Article 9), with stricter rules for using them at all.
- EU countries can set their own rules for employee data (Article 88), so check your national law and works agreements too.
- Data minimisation (Article 5) applies to every use: send only what the recipient needs.
Column by column
| Column | What to do |
|---|---|
| Name, email, phone, address | Remove, or fake if the file must look real |
| Employee ID | Keyed hash or consistent fake, so files still join |
| National ID number | Remove, or fake with a valid test number |
| Date of birth | Birth year, or an age band |
| Salary | Bands (for example in steps of 500 or 1,000) |
| Start date | Year, or year and month |
| Postal code | First two digits |
| Sick leave, notes, comments | Leave out unless the analysis needs it |
| Department, grade, location | Keep, but watch small groups |
Watch the small groups
Without a name, "the only woman in the Oulu finance team, born 1971" is still one person. Before you share, look for combinations of department, location, grade and age that describe only a few people, and generalize further or merge those groups.
Doing it with Scrubsheet
Scrubsheet suggests a method for each column. Generalize turns dates into years or year and month, numbers into bands of the width you choose, and postal codes into their first digits. Hash or Fake with consistent output keeps employee IDs joinable across exports. The browser tool runs on your computer, so the HR file is not uploaded anywhere to be anonymized.
This guide explains the rules as we understand them; it is not legal advice. Whether a particular dataset is anonymous depends on its content and on who receives it.
Try it on your own file. The Scrubsheet browser tool anonymizes Excel and CSV files in your browser, free and without uploading anything. In Excel, use the Scrubsheet add-in.
Anonymize a spreadsheet