OpenCodelists

OpenSAFELY codelists

Published codelists

All of the codelists published by OpenSAFELY

Name Coding system Description Last updated
Depression CTV3 The following codes are used to indicate Depression
Dexamfetamine - dmd dm+d dm+d codelist for dexamfetamine
Diabetes CTV3 Codes indicating diagnosis of permanent diabetes
Diabetes (SNOMED) SNOMED CT Automatically-generated equivalent of [Diabetes](/codelist/opensafely/diabetes/)
Diabetes Ketoacidosis - CTV3 (DKA - unspecific) CTV3 This lists contains CTV3 codes used to identify people who may have had diabetes ketoacidosis (DKA). It has been generated based on a [DKA snomed list](https://codelists.opensafely.org/codelist/opensafely/diabetes-ketoacidosis-snomed-dka-unspecific/2020-10-06/) using internal mappings. The SNOMED codelistlist was conceived to identify DKA in a specific group of patients in a specific time period, therefore we have been permissive in including unspecific codes which may not be suitable for all …
Diabetes Ketoacidosis - SNOMED (DKA - unspecific) SNOMED CT This lists contains codes used to identify people who may have had diabetes ketoacidosis (DKA). This list was conceived to identify DKA in a specific group of patients in a specific time period, therefore we have been permissive in including unspecific codes which may not be suitable for all studies.
Diabetes Unknown Type CTV3 Codes which likely indicate either Type 1 or Type 2 diabetes but are ambiguous.
Diabetic Ketoacidosis (Secondary Care) ICD-10 ICD-10 codes for Diabetic Ketoacidosis
Dialysis CTV3 Codes indicating dialysis treatment, or preparation for dialysis
Diamorphine subcutaneous dm+d This code list contains diamorphine formulations which may be given subcutaneously.
Direct Acting Oral Anticoagulants (DOAC) dm+d This is a codelists that identifies all prepartaions from the [NHS dictionary of medicines and devices](https://ebmdatalab.net/what-is-the-dmd-the-nhs-dictionary-of-medicines-and-devices/) for Directing Oral Anticoagulants better knows as DOACs. They have previously been know as NOACs.
Documented Influenza illness CTV3 Codes indicating a diagnosis of influenza or influenza-like illness
Down syndrome CTV3 Diagnoses of Down syndrome
Doxycycline medication BNF
Drugs which increase the risk of vitamin D deficiency dm+d This codelist aims to identify drugs that substantially increase the risk of vitamin D deficiency when administered on a long-term basis.
Dulaglutide dm+d This codelist aims to identify the prescribing of dulaglutide.
Dyslipidemia SNOMED CT This codelist aims to identify patients who have dyslipidemia.
Edoxaban DM+D dm+d This is a codelist that identifies all preparations from the NHS dictionary of medicines and devices for edoxaban, one of the Directing Oral Anticoagulants which are often referred to as DOACs.
English not main language (excluding interpreter codes) SNOMED CT A list of codes indicating a main spoken language that is not English.
Erythromycin (oral) dm+d This codelist contains erythromycin formulations which may be given orally.
Ethnicity CTV3 A list of ethnicity codes in use in UK general practice including aggregate grouping at two levels.

5+1 category labels are:
Ethnicity (SNOMED) SNOMED CT Automatically-generated equivalent of [Ethnicity](/codelist/opensafely/ethnicity/)
Exenatide dm+d This codelist aims to identify the prescribing of exenatide.
Explicit contraindication to DOACs (direct acting anticoagulants) CTV3 This is a codelist that identifies SNOMED codes where a Directing Oral Anticoagulants (DOACs) is explicitly contraindicated. They have previously been know as NOACs.
Falls CTV3 The following codes are used to indicate Falls
Final Orthopaedic Surgery ELECTIVE Procedure OPCS codes SC OPCS-4 OPCS-4 codes for all ELECTIVE, or non-emergency, orthopaedic procedures.
Final Orthopaedic Surgery Emergency Procedure OPCS codes SC OPCS-4 OPCS-4 codes for all emergency orthopaedic procedures
First Generation Antipsychotics excluding long acting depots DM&D dm+d This code list contains the DM&D list of medicines that are known as First Generation Antipsychotics. All formulations of these medicines have been included, except for long acting depot antipsychotics and all formulations of prochlorperazine which are included in separate code lists. All of these antipsychotics are dopamine antagonists and licensed in some form for the treatment of psychosis, although some (e.g. flupentixol) may be licensed and used for other indications such as depression. D…
Fracture Risk Assessments SNOMED CT This codelist aims to identify people who have had an assessment which evaluates the risk of bone fractures.
Fracture potential emergency OPCS codes OPCS-4 These are general fracture fixation OPCS-4 procedural codes
These OPCS-4 procedure codes need an additional ICD-10 diagnosis code to confirm that it was for an emergency rather than non-emergency procedure (defined as urgent or elective)
Emergency surgery defined as P1a and P1b as per Royal College of Surgeons Surgical Prioritisation Guidelines
Fragility CTV3 Codelist for creating binary variable capturing fragilities/fractures
GI Bleed or Ulcer CTV3 Codes indicating diagnosis of either a GI bleed or a GI ulcer
GI Bleed or Ulcer (SNOMED) SNOMED CT Automatically-generated equivalent of [GI Bleed or Ulcer](/codelist/opensafely/gi-bleed-or-ulcer/)
GLP-1's (excluding those combined insulin) - dmd dm+d This codelist contains NHS Dictionary of Medicines and Devices (dm+d) codes for GLP-1 mimetics, excluding products which are combined with insulin. Note that some GLP-1 products are licenced for the indication of diabetes and some for the indication of weight loss; all indications are included in this codelist.
GLP-1's in combination with insulin - dmd dm+d This codelist contains NHS Dictionary of Medicines and Devices (dm+d) codes for products which contain a GLP-1 mimetics in combination with insulin.
Gastrointestinal bleeding ICD-10 ICD-10 Codes to define gastrointestinal bleeding in ONS death data.
Giant Cell Arteritis CTV3 Codes indicating a diagnosis of Temporal Arteritis or Giant Cell Arteritis
Glucocorticoids associated with high risk of osteoporosis dm+d This codelist aims to identify glucocorticoids that are associated with a high risk of osteoporosis when administered on a long-term basis.
Glycated haemoglobin (HbA1c) tests SNOMED CT A SNOMED CT codelist for patients receiving monitoring of glycated haemoglobin (HbA1c) tests.
Glycated haemoglobin (HbA1c) tests (numerical value) SNOMED CT A SNOMED CT codelist for patients receiving monitoring of glycated haemoglobin (HbA1c) tests, which contains a numerical value using the newer IFCC units.
Glycated haemoglobin (HbA1c) tests — IFCC standardised CTV3 A CTV3 codelist for patients receiving monitoring of glycated haemoglobin (HbA1c) tests using reference methods standardised by the International Federation of Clinical Chemistry and Laboratory Medicine (IFCC).

Note that for tests before 2018, test values in the East region appear to be recorded on a different scale (approximately 4 to 8-times greater than mean values in other regions). This issue is being investigated.
Glycopyrronium - Subcutaneous Formulations dm+d This codelist contains all subcutaneous formulations of glycopyrronium.
Group A Streptococcal sore throat / tonsillitis SNOMED CT Following an increase in cases of [Scarlet Fever and invasive Group A Strep in the UK](https://ukhsa.blog.gov.uk/2022/12/05/group-a-strep-what-you-need-to-know/) this codelist aims to identify patients who have had a possible diagnosis of Streptococcal sore throat.

We have taken a pragmatic approach where by codes for sore throat/pharyngitis/tonsilitis have been included where an alternative cause for the sore throat is not stated (eg. Viral sore throat). This codelist will be used in conjun…
Guanfacine - dmd dm+d dm+d codelist for guanfacine
Guillain Barre CTV3 CTV3 codelist for Guillain Barre syndrome

To be used in conjunction with ICD-10 code G61.0 'Guillain Barre syndrome'
Guillain Barre syndrome - ICD10 ICD-10 Guillain-Barre syndrome ICD-10 codelist for use with hospital admissions and mortality data
HIV CTV3 Codes indicating a diagnosis of HIV
HIV (SNOMED) SNOMED CT Automatically-generated equivalent of [HIV](/codelist/opensafely/hiv/)
HIV Codes SNOMED CT This codelist contains codes used to indicate a HIV diagnosis.
HS CTV3 todo