Skip to content

What patient data is made available in OpenSAFELY-TPP?đź”—

Backgroundđź”—

The OpenSAFELY-TPP databaseđź”—

In England, the vast majority of General Practices (GPs) use GP IT Systems supplied by one of two GP IT System Suppliers (GPSSs), TPP and Enlivio (formerly EMIS/Optum). These GPSSs securely store data for GPs for the purposes of direct care. 

The NHS England OpenSAFELY Analytics Service (“the Service”) creates a safe way to analyse GP data securely held by these two GPSSs for the purposes of research and service evaluation. 

The OpenSAFELY-TPP database is built within the secure GP data environment managed by TPP. It is a modified copy of the raw GP data that is created for use by the Service. To meet data minimisation principles and mitigate disclosure risk, the data that is included in OpenSAFELY-TPP and available to Users differs from the raw GP data in the following ways:

  • certain identifying data is removed, pseudonymised, or coarsened;

  • all free text data is removed;

  • a small set of coded events relating to special category data, for example assisted fertility and pregnancy termination, are removed (see the Data Protection Impact Assessment (DPIA) for the OpenSAFELY Service for more details);

  • only data items that have been deemed useful for research purposes is available.

Additionally, some patient data are unavailable due to:

  • patients who have opted-out of data sharing (through the type 1 opt-out);

  • practices that have not “activated” (that is, who have not acknowledged their legal obligation to share data with the Service);

  • practices that have closed (but some data from closed practices is available);

  • a historic cut-off (patient registrations ending prior to 1 January 2009).

The data that is made available to Users, and how this may change over time, relates to data controllership and the activation status of practices. These concepts are introduced below. 

This page describes the data currently available in OpenSAFELY-TPP under the current legal basis. If you have further questions not covered in this document, please contact us. 

Data controllershipđź”—

NHS England is the controller of the OpenSAFELY Service, which uses the OpenSAFELY platform to process GP controlled and NHS England controlled patient data, both held within a Secure Data Environment (SDE) inside TPP’s systems. 

General Practices are the data controller for the pseudonymised copy of the raw GP data made available inside the OpenSAFELY-TPP SDE. NHS England permits patient data they control – such as hospital data – to be ingested within this SDE and link it to the GP controlled patient data, creating the OpenSAFELY-TPP database as a whole (which now comprises both GP controlled data and NHS England controlled data). TPP are data processors for this linkage. Approved users are able to send queries that run against the OpenSAFELY-TPP database to generate study-specific datasets and analytic results, which remain within the secure boundaries of the SDE. NHS England is the data controller for outputs derived from processing the database in this way. 

As data controllers for the OpenSAFELY Service, NHS England are responsible for approving projects and users of the Service. 

GP data and registrationsđź”—

All GP practice data made available to OpenSAFELY-TPP for processing is from live TPP GP practices, and these practices remain the data controller of this patient data. Once the GP data has undergone any processing by an OpenSAFELY approved project, the results of that processing (e.g. a study-specific dataset or analytic results) are controlled by NHS England.

When a patient registers at a TPP practice, the practice gains access to i) GP data entered at any TPP practices that the patient was previously registered with, and ii) any data transferred from historic non-TPP registrations via the GP2GP service, where successful. The practice is the data controller for the patient data it can access, as it has a direct care relationship with the patient and, for their purposes (e.g. continuity of care and patient safety), must be able to access (where technically feasible) the patient record as a whole. Importantly, deregistration from a practice does not remove that practice’s status as a data controller for the data processed during the registration period. Therefore, data remains in the TPP database after deregistration. Processing of patient data for purposes beyond direct care, whether before or after deregistration, requires a lawful basis; for OpenSAFELY analyses, this lawful basis stems from statutory obligations for data sharing under NHS England Directions. These Directions allow a practice to share data for patients who are currently or previously registered with them.

Controllership of GP data is held by live practices. If a TPP practice closes, controllership of the data held by the closing practice is transferred to a successor practice. If the successor practice also uses TPP, all patient data (including data from patients who have deregistered, for example due to death, emigration, or moving practices) from the closing practice is transferred, and remains available within OpenSAFELY-TPP. However, if the successor practice uses Enlivio, all the patient data that was made available in OpenSAFELY-TPP by the now closed TPP practice will disappear. 

Similarly, if the TPP practice remains open, but changes from TPP to Enlivio, all the patient data that was made available by that TPP practice will disappear from OpenSAFELY-TPP.  

Practice activationsđź”—

Each live practice is legally obliged to share data with the Service. They acknowledge this obligation by “activating” a feature inside their GP IT System. As of September 2026, 96.6% of practices using TPP were activated.

Only activated TPP practices provide data to OpenSAFELY-TPP. However, activated TPP practices may include historic data from non-activated practices (either TPP or non-TPP) due to patients moving from a non-activated practice to an activated TPP practice and data being transferred from the old to the new practice. 

If a practice closes, the activation status of the practice before it closed is no longer relevant – what matters is the activation status of the successor practice (see data custodianship above). 

Practice activation status is not shared between GPSSs. Therefore, the activation status of a non-TPP practice does not affect the data that is available to Users in OpenSAFELY-TPP.

Patient identifiers and registration periodsđź”—

The patient pseudo identifier persists across multiple registration periods at different practices, including if a patient moves from TPP to Enlivio and back again. It is therefore possible to link a single patient across multiple registration periods and GP IT Systems, assuming the data available to Users.

Data availabilityđź”—

Figure 1. Flowchart summarising which patients and GP data are available to Usersđź”—

Flowchart patients and GP data to OS users.

In essence, the data available to Users includes: all patients currently registered at live and activated TPP practices; all patients previously deregistered from live TPP practices (e.g. patients who have died, patients who have moved to a non-TPP practice, and patients who have emigrated abroad); and all (unregistered) patients whose data is currently under controllership of a live TPP practice following a practice merger. 

Practice registrationsđź”—

If a patient was ever registered at a TPP practice on or after 1 January 2009 (i.e., where the registration end date is after 1 January 2009), their data is available to Users, subject to other restrictions due to opt-outs, non-activated practices, and closures. 

Practice closuresđź”—

If a practice closes, all patient data (both currently registered and deregistered patients) are transferred to a successor practice. The successor practice is either an existing practice, or a new practice. The closing practice’s Organisation Data Service (ODS) Code is retired. The successor practice will have an existing ODS code, or for a new practice a new ODS code is created. 

The availability to Users of data from a closed practice depends on status of the successor practice:

  • If a closing TPP practice merges with another TPP practice, all patient data collected at the closing TPP practice remains available to Users via the successor practice, including for deducted patients. 

  • If a closing TPP practice merges with a non-TPP practice (e.g., TPP to Enlivio), all patient data collected at the closing TPP practice is no longer available to Users. However, if any patients at the closed TPP practice had prior registrations at other live TPP practices, their data will still be available to Users.

  • If a TPP practice switches to Enlivio, all patient data collected at the practice whilst using TPP is no longer available to Users.

Therefore, if a patient has only ever been registered with a TPP practice that has since closed or migrated to a different GPSS, and the patient does not later re-register with a live TPP practice, then no data for the patient is available to Users. 

Non-activated practicesđź”—

Data collected whilst patients are registered at non-activated practices (those who have not acknowledged their legal obligation to provide data to the Service, as above) is not made available to Users unless a patient has since moved to an activated practice. More precisely: for each patient, the Service includes all GP data collected up until the date a patient registers with a non-activated practice; if the patient subsequently registers with an activated practice, any historic data collected at non-activated practice is included.

For example:

  • If a patient was registered with a non-activated practice and then moved to an activated practice, all data collected for that patient is available to Users.

  • If a patient was registered with an activated practice and then moved to an non-activated practice, all data for that patient collected up until the date that the patient moved to the non-activated practice is available to Users, but not beyond this date unless they later move to an activated practice. 

  • If a patient was never registered with an activated TPP practice, no data is available to Users, unless an activated practice inherits controllership of data due to a practice merger (see practice closures, above).

Although data collected whilst a patient is registered at a non-activated practice is available to Users if they subsequently register with an activated practice, a patient’s registration history spanning periods with non-activated practices will be incomplete. The patient registration table in the OpenSAFELY-TPP database captures which practice a patient was registered with on any given date. The registration table only includes registrations at activated practices. Periods of registration at non-activated practices are excluded from this table. However, GP-recorded patient events (symptoms, diagnoses, medications, etc) occurring during any period of registration, whether at an activated practice or non-activated practice, will be included as per rules on inclusion of data from live and non-activated / activated practices, outlined above.

As of September 2026, 96.6% and 94.6% of practices using TPP and Enlivio were activated respectively.

Type 1 Opt-Outs (T1OO)đź”—

Patients can register a Type 1 Opt-Out (T1OO) with their GP practice: their data will not be shared for any purposes beyond their direct care. If a patient has ever registered a T1OO at a TPP practice, no data for this patient is made available to Users including any data recorded in TPP before the date the opt-out was registered. 

During practice mergers or migrations to a non-TPP GP IT system, the T1OO data item is also transferred and upheld. 

A known limitation exists in the following scenario: a patient de-registers from a TPP practice and re-registers at a non-TPP practice where they register a T1OO. Whilst the patient continues to be registered at non-TPP practice(s), any of their data held in live TPP practices will continue to be made available to Users. This limitation exists because TPP and non-TPP practices do not reconcile T1OOs data for patients as a standalone service; T1OO data are only moved to a new practice during mergers, migrations or a patient transferring to a different practice.

As of June 2018, there were almost 1.9 million T1OOs in English GP records. Counting of this number stopped in November 2018. 

National Data Opt-Outs (NDOO)đź”—

Patients can register a National Data Opt-Out (NDOO): their confidential data is not used for research or planning purposes. With respect to OpenSAFELY, the NDOO is not required to be upheld by default. The NDOO is upheld if: project researchers request that the NDOO is upheld (for example, a favourable ethical opinion for the study was contingent on the NDOO being upheld).

If the project request to uphold the NDOO is granted then no data for patients who have registered a NDOO are made available to Users, including any data collected before the opt-out was registered. As of January 2026, the proportion of registered patients in England with a National Data Opt-Out is around 5.5%.

Upholding the NDOO may be subject to the same limitation described above for the T1OO. 

Registration typeđź”—

There are different types of NHS GP contracts that practices can hold to provide services to patients. Patients who are fully registered with practices holding either a General Medical Services (GMS) contract, a Personal Medical Services (PMS), or a Alternative Provider Medical Services (APMS) contract are included in the Service. Patients who are temporarily registered with a practice, for example temporary residents or tourists, are not included. Therefore, only data from full registrations are available to Users. 

For more on GP contracts, see the GP funding and contracts explainer from the King’s Fund. 

OpenSAFELY-TPP database updates and changes to the patient populationđź”—

Patient data is made available to Users if and only if it meets the criteria as set out above.

The database is updated on at least a monthly basis, and the set of patients made available to Users changes with each update, for the following reasons:

  • (+) Patients are added due to being registered with an activated TPP practice for the first time, for example due to births, immigration, or moving from a non-TPP practice.

  • (+) Patients are added due to a TPP practice activating.

  • (+) Patients are added due to a non-TPP or non-activated practice merging with an activated live TPP practice. This will add both registered and deducted patients (TBD).

  • (-) Patients are removed due to expressing a Type 1 Opt Out.

  • (-) Patients are removed due to being: (a) registered with an activated practice that closes and merges with a non-activated or non-TPP practice, or migrates to a different GP IT System; AND (b) not previously registered with another activated, live practice.

  • (-) (Rarely) Patients are removed due to data integrity processes, e.g., deduplication. 

Linked non-GP datađź”—

All non-GP patient level data ingested into OpenSAFELY-TPP, for example hospital data and mortality data, are linked on the patient pseudo-identifier for patients whose GP data is available to Users (i.e., a left join of non-GP data onto GP data); this is patients included in the green box in Figure 1 above. Importantly, this linked data will be included irrespective of the registration status of the patient on any given date (the left join does not incorporate registration dates, only patient pseudo-identifiers). For example, if a patient deregistered from an activated practice in June, then was hospitalised in July, and then died in August, the hospital and death events for that patient are still included. Similarly, events in linked datasets occurring before registration are included, as far back as data is available. 

How is this different to the data available to Users under the previous iteration of the OpenSAFELY Service?đź”—

The key difference is that there were no activation-based practice rules in the previous Service; all data across all live practices in TPP, whether activated or non-activated, were available to Users (the type-1 opt-outs were still upheld). From February 2026, the OpenSAFELY Service does not make available to Users patient activity occurring whilst a patient was registered with a non-activated practice, unless the patient subsequently registers with an activated practice. This essentially treats non-activated practices as a separate, inaccessible database (similar to how OpenSAFELY-TPP and OpenSAFELY-Enlivio are separate databases). However, unlike the TPP/Enlivio separation, activated and non-activated practices are managed by the same GPSS, so if a patient moves from a non-activated to an activated practice, all information recorded during previous registration will be available under the new registration. This isn’t always possible if a patient moves from TPP to Enlivio (or vice versa), although the GP2GP service does capture much activity well.