Anonymising Research-Cohort Datasets for HRA Studies – UK GDPR-compliant anonymisation per Health Research Authority guidance

A research-cohort dataset is a structured collection of special-category health data compiled for a Health Research Authority-approved study, linking patient identifiers to longitudinal outcomes under UK GDPR Article 9. The HRA approves around 6,000 projects per year; NHS Digital holds over 30,000,000 GP records. anonym.legal pseudonymises direct and indirect identifiers, preserving analytical variables and biomarker values for the approved research purpose.

When this applies

This task applies when a research team is preparing a cohort dataset for analysis under an HRA-approved protocol and requires pseudonymisation of participant identifiers before the dataset is transferred to the analysis team or uploaded to a safe haven environment. Breaches of research participant confidentiality can attract fines of up to £17.5 million or 4% of annual global turnover under DPA 2018 s.157.

  1. Upload the cohort dataset (CSV, XLSX, or SAS format) to anonym.legal.
  2. The engine identifies direct identifiers (name, NHS number, date of birth, postcode) and flags quasi-identifiers (age, sex, rare diagnosis codes) for review.
  3. Direct identifiers are replaced with consistent participant pseudocodes.
  4. Quasi-identifier combinations are reported to the researcher for a disclosure-risk assessment before the dataset is released.
  5. Outcome variables, biomarker values, and survey responses are preserved; date variables are generalised to month/year where full dates carry re-identification risk.
  6. A mapping table linking pseudocodes to real participant identities is stored with UK data residency under the Data Controller's access policy.

What you provide

  • Cohort dataset file (CSV, XLSX, or SAS)
  • Data dictionary describing all variables and their sensitivity level
  • HRA approval reference and approved data-minimisation plan

Limitations & cautions

  • HRA guidance requires researchers to demonstrate data minimisation; pseudonymisation alone may not satisfy requirements for datasets with high quasi-identifier density — obtain a statistical disclosure-control report. According to the ICO's Anonymisation Code of Practice (2012, updated 2021–22), pseudonymisation does not produce anonymous data; it remains personal data under UK GDPR.
  • The tool does not assess whether the research falls within the scope of the HRA ethics approval — confirm with your Research Ethics Committee.
  • Date-of-birth generalisation to age bands may reduce analytical precision; agree the generalisation strategy with the Chief Investigator before processing.

FAQ

Does HRA guidance require full anonymisation or is pseudonymisation sufficient for safe-haven data transfers?

HRA guidance supports pseudonymisation as an appropriate protection measure for approved health research, particularly within NHS Digital safe-haven environments. Full anonymisation (irreversible) may be required for public data releases. Confirm with your HRA-approved data access agreement. The HRA approves around 6,000 research projects per year, many of which rely on pseudonymised cohort extracts transferred to accredited safe havens.

Can the engine handle cohort datasets with linked hospital episode statistics?

Yes. Linked HES data joined to cohort records is processed in a single batch. The same participant pseudocode is applied across cohort and HES tables, preserving linkage keys while removing identifiable fields. The NHS Records Management Code of Practice 2023 requires adult health records to be retained for 8 years from the end of treatment — cohort datasets derived from NHS records must respect this obligation.

How does the engine handle rare disease codes that act as quasi-identifiers?

The engine flags rare diagnosis codes (those appearing in fewer than a configurable threshold of participants in the dataset) for researcher review. The researcher decides whether to suppress, aggregate, or retain those codes before final pseudonymisation. The 8 Caldicott Principles (updated 2013, Principle 8 added 2020) require that data flows are minimised and documented.

Healthcare Records

About this page

We update this page when our platform or the law changes.

Read our founder note for how we work.

Each change shows up in the timestamp at the top.

We follow these rules

  • GDPR (EU 2016/679).
  • ISO/IEC 27001:2022.
  • NIS2 (EU 2022/2555).
  • HIPAA safe harbor under 45 CFR § 164.514(b)(2).

Our promise

We do not sell your data.

We do not train models on your text.

We store your files in Germany.

You can delete your account at any time.

You own your work.

Where we run

Our company HQ is in Saarbrücken, Germany. Our servers run in Hetzner's Falkenstein datacenter.

Hetzner holds ISO 27001 certification.

All data stays in the EU.

Backups run every day.

Need help?

Email support@anonym.legal.

We reply within one business day.

How we test

We run a full check suite on every release.

Each surface gets its own sweep script and report.

Human reviewers spot-check the output each week.

We track recall and precision on a labelled set.

Bad runs block the deploy.

What we never do

  • We never sell your information to third parties.
  • We never train models on what you upload.
  • We never keep your work after you delete it.
  • We never share keys with any outside firm.
  • We never run ads inside the product.

Plans in plain words

We sell credits, not seats.

One credit covers one short job.

Long jobs use a few credits each.

You can top up at any time.

Unused credits roll over each month.

Read the plans page for current rates.

Who built this

A small team of engineers and lawyers built this.

We ship from Europe and work in the open.

Our founder note spells out why we started.

Where to start

How the parts fit

A browser add-on cleans text inside Chrome.

A Word plug-in handles drafts in Office.

A small desktop tool works on whole folders.

An agent protocol link feeds large models safely.

All four share one core engine and one rule set.

Words from our team

We started this work after a lunch about cookies.

One friend kept getting odd ads on her phone.

We asked why a court file leaked through a draft.

We sketched the first build on a napkin that week.

By month three we had a tiny demo for a friend.

She used it on her first case the next day.

Common questions we hear

Can the tool read scanned PDFs? Yes, with OCR.

Does it work on long files? Yes, in small chunks.

Can I roll my own rule set? Yes, save it as a preset.

Does it run offline? The desktop build runs offline.

Do you keep my files? No, the cloud build wipes after each run.

Will it learn from my work? No, we never train on inputs.

A short tour of the workflow

Upload a file or paste a snippet of prose.

Pick the entities you want gone from the draft.

Choose a method: replace, mask, hash, encrypt, or redact.

Press run and watch the side panel show each hit.

Skim the result and tweak any rule that misfired.

Save the cleaned file or send it to a teammate.