Skip to content

Instantly share code, notes, and snippets.

@jakebathman
jakebathman / icd_regex.md
Last active October 12, 2023 09:31
ICD-9 and ICD-10 code regex

ICD code matching regex

The regex patterns below only help validate when something is not valid ICD-10 or ICD-9. They do not ensure that the code exists. You should consult a list of valid ICD codes for that level of verification.

ICD-10-CM list: https://gist.github.com/jakebathman/063c50cb9772e4bfc864a9e1ff4ccc8d

ICD-9 list: https://gist.github.com/jakebathman/f1ed0d473f12091a708243b0ddf03d82

ICD-10/ICD-9 combined regex

Useful for validating field values that could contain both, and may or may not use decimals