DocsAPI LogoDocsAPI

HIPAA Deidentification Automation: The 18 Identifiers

A discharge summary can pass every automated PHI scrubber and still identify the patient. Here is why, and what Safe Harbor actually requires.

Nupura Ughade
Nupura Ughade
|
August 31, 2026
|
11 min read
HIPAA Deidentification Automation: The 18 Identifiers

A hospital in a rural county runs a discharge summary through its automated PHI scrubber before sending it to a research partner. The tool does its job well: patient name gone, address gone, phone number gone, dates shifted to year-only, medical record number stripped. By every visible measure, the document passes. And yet a single sentence buried in the clinical narrative, "patient diagnosed with a form of Erdheim-Chester disease, a condition with fewer than 1,000 documented cases worldwide, and referred to the regional oncology center serving a county of roughly 12,000 residents," is enough for anyone who knows the patient's community to identify exactly who this document describes. Nothing in that sentence looks like PII. No name, no number, no address. It passed the scrubber because pattern-matching redaction tools are built to find things shaped like identifiers, and a rare disease name paired with a small population is not shaped like one.

This is the actual mechanics problem sitting underneath the compliance checkbox that most guidance on this topic never gets into. Handling medical documents at scale, discharge summaries, referral letters, progress notes, pathology reports, means running redaction across free-text clinical narrative, not clean structured fields, and that is precisely where automated Safe Harbor de-identification most often fails quietly. This post covers the actual 18 identifiers as HIPAA defines them, the specific sub-rules inside that list that automated tools routinely get wrong, why certain identifiers evade pattern-based detection entirely, and the real technical difference between Safe Harbor and Expert Determination, the regulation's other, statistically grounded de-identification path.

What "de-identified" actually means under the Privacy Rule

HIPAA does not treat de-identification as a vague best-effort standard. It is defined in 45 CFR 164.514, and the regulation gives covered entities exactly two ways to satisfy it. Section 164.514(b)(2) is the Safe Harbor method: remove a specific, enumerated list of 18 identifier categories, and have no actual knowledge that the remaining information could still identify someone alone or in combination with other available data. Section 164.514(b)(1) is Expert Determination: have a qualified person apply generally accepted statistical and scientific methods to determine that the risk of re-identification is very small, and document that analysis. Both methods produce information that is, legally, no longer PHI once they are correctly applied. Neither is a suggestion or a best practice, they are the only two routes the regulation recognizes, and they work on genuinely different logic, which matters more than most compliance content acknowledges.

The 18 identifiers, exactly as the regulation lists them

Safe Harbor is deliberately mechanical. It does not ask whether a piece of information is risky in context, it asks whether it falls into one of 18 defined categories, full stop. That bright-line design is the entire point, it lets a covered entity apply the rule without hiring a statistician. Here is the complete list under 164.514(b)(2)(i), for the individual or for the individual's relatives, employers, or household members.

#Identifier categoryNotable sub-rule
1NamesFull or partial, including nicknames used in the record
2Geographic subdivisions smaller than a stateStreet address, city, county, precinct; ZIP code allowed only at the first three digits, and only if that three-digit region contains more than 20,000 people, otherwise it must be zeroed out
3All elements of dates directly related to an individual, except yearBirth date, admission date, discharge date, death date; ages over 89 must be aggregated into a single "90 or older" category
4Telephone numbersAny format
5Fax numbersAny format
6Email addressesAny format
7Social Security numbersFull or partial
8Medical record numbersInternal or cross-facility
9Health plan beneficiary numbersInsurance member IDs
10Account numbersBilling or financial account references
11Certificate or license numbersProfessional or personal licenses
12Vehicle identifiers and serial numbersIncluding license plate numbers
13Device identifiers and serial numbersImplants, pumps, monitors referenced in the record
14Web URLsAny format
15IP addressesAny format
16Biometric identifiersFinger and voice prints named explicitly in the rule
17Full-face photographs and comparable imagesAny image that could identify the individual, not just headshots
18Any other unique identifying number, characteristic, or codeThe catch-all, except a re-identification code assigned by the covered entity itself that is not derived from PHI

Most compliance content stops here, reprints this list, and calls the topic covered. But three of these rows contain sub-rules that automated tooling gets wrong constantly, and one row, the eighteenth, is doing far more work than a single line in a table suggests.

The three sub-rules automated tools routinely get wrong

The ZIP code rule is not "remove ZIP codes." It is "you may keep the first three digits, but only if the population of everyone sharing that three-digit prefix exceeds 20,000, and if it doesn't, those three digits must be replaced with 000." A redaction pipeline that treats all five-digit ZIPs the same way, truncating every one to three digits and calling it compliant, is wrong for every low-population three-digit prefix in the country, and the Census Bureau publishes the list of which three-digit prefixes fail that threshold. A tool that doesn't reference that list isn't actually implementing the rule, it's implementing an approximation of it that happens to work most of the time.

The date rule is not "remove dates that look like PII." It requires removing every date element tied to the individual, birth date, admission date, procedure date, discharge date, death date, except the year, and it applies to dates written in any format: numeric, spelled out, relative ("three weeks after her 62nd birthday"), or embedded in a narrative sentence that a rule-based regex was never written to catch. The age rule compounds this: any age over 89, and any date element that would let someone calculate an age over 89, has to be generalized into a single "90 or older" bucket, because ages that high are rare enough in a population to function as identifiers on their own.

The catch-all, category 18, is the one that does the most damage when automated tooling ignores it, because by definition it cannot be captured by a fixed list of patterns. It covers anything that functions as a unique identifier even though it doesn't look like one: an unusual job title held by one person in a facility, a rare combination of demographic details, a distinctive treatment history, or, as in the opening example, a rare disease name. Software built to detect the first 17 categories is built to recognize shapes, digit sequences, known name dictionaries, address formats. Category 18 has no shape. It requires understanding what a piece of information means in context, not what it looks like.

Why pattern-matching redaction misses identifiers that don't look like PII

Automated de-identification tools generally work one of two ways: rule-based pattern matching (regex for SSN and phone formats, dictionary lookups for common names, date-format detection) or named-entity recognition models trained to tag PERSON, LOCATION, DATE, and similar entity types in free text. Both approaches are genuinely effective against the identifiers with a predictable shape, names, dates, phone numbers, SSNs, medical record numbers, because those categories were designed for exactly this kind of detection to work well.

The categories that break this approach share one trait: their risk comes from rarity in context, not from format. A diagnosis code or disease name is not inherently identifying, most diagnoses are shared by thousands of people. But a rare diagnosis, one affecting a small enough population, becomes identifying the moment it's combined with even a coarse geography. An NLP model tagging clinical entities has no population-frequency data attached to what it's tagging, it can correctly recognize "Erdheim-Chester disease" as a MEDICAL_CONDITION entity and have no basis at all for knowing that entity, unlike "type 2 diabetes," is rare enough to function as an identifier. The model isn't malfunctioning, it's doing exactly what it was built to do, tag entities by type, not by re-identification risk, because re-identification risk isn't a property of the text, it's a property of the text combined with population statistics the redaction tool was never given.

The same failure mode hits occupation, employer names, unusual life events referenced in a social history section, and device identifiers written into a narrative rather than a structured field, "the patient's cardiac monitor, serial number ending in the digits referenced during the cardiology consult," is category 13 and a pattern-matcher tuned for standalone serial-number formats can miss it entirely when it's woven into a sentence instead of sitting in a labeled field.

Where this shows up hardest in medical document processing

Structured data fields, patient name field, DOB field, MRN field, are the easy case, and automated tools handle them close to perfectly because the identifier's location and format are both known in advance. The hard case is free-text clinical narrative: discharge summaries, physician progress notes, referral letters, social history sections, and pathology or radiology report impressions. These documents are written by clinicians in natural language, for other clinicians, with no structural markers indicating which sentence contains a category-18 risk and which doesn't. A document intake pipeline that runs Safe Harbor redaction only against known field types and skips deep narrative sections, because narrative text is harder to process reliably, is the single most common gap between "we run PHI redaction" and "we are actually Safe Harbor compliant" in practice.

Safe Harbor vs Expert Determination: the real technical difference

Most content on this topic describes Expert Determination as "the other option, for when Safe Harbor removes too much data," which is true but skips the actual mechanism. The two methods are built on entirely different logic.

Safe Harbor is deterministic and categorical. The regulation defines a fixed list, you either removed everything on that list or you didn't, and the standard doesn't ask about the actual statistical risk of the remaining data, only about actual knowledge. This is why it's usable without specialized expertise, and it's also why it's blunt: it can't distinguish between a ZIP code that's genuinely risky in combination with other fields and one that isn't, it just requires the same three-digit truncation rule everywhere.

Expert Determination, defined in 164.514(b)(1), works the opposite way. The regulation's own text requires "a person with appropriate knowledge of and experience with generally accepted statistical and scientific principles and methods for rendering information not individually identifiable" to apply those methods and determine that "the risk is very small that the information could be used, alone or in combination with other reasonably available information, by an anticipated recipient to identify an individual who is a subject of the information," and to document the methods and results that justify that determination. HHS does not mandate a specific statistical technique, but accepted approaches generally involve quantifying re-identification risk directly, techniques like k-anonymity (ensuring each record is indistinguishable from at least k-1 others on the quasi-identifiers present), generalization (widening a specific value, an exact age, into a range), and suppression (removing a field entirely when generalizing it wouldn't sufficiently reduce risk), applied selectively based on what the dataset actually contains and who will receive it.

The practical consequence: Safe Harbor treats every three-digit ZIP under the population threshold identically, whether or not it's genuinely risky given the rest of the dataset. Expert Determination can look at the same ZIP code sitting next to a rare diagnosis and a specific age, recognize that combination as high risk even though none of the three fields alone is, and either generalize or suppress accordingly, while potentially leaving other, genuinely low-risk fields in the same dataset untouched that Safe Harbor's checklist would have stripped anyway. Expert Determination can preserve more analytic value in a dataset precisely because it isn't bound to a fixed list, but that flexibility is exactly why it requires a qualified expert and documented methodology rather than a checklist a compliance team can run through unassisted.

DimensionSafe Harbor (164.514(b)(2))Expert Determination (164.514(b)(1))
Underlying logicFixed checklist of 18 categoriesStatistical risk quantification
Who can apply itAny covered entity, no special credentials requiredA person with statistical/scientific expertise in re-identification methods
Handles quasi-identifier combinationsNo, treats each category identically regardless of contextYes, evaluates fields jointly against the actual dataset and recipient
Documentation requiredNot required by the rule itselfRequired, methods and results must be documented and available to OCR
Typical data utility outcomeLower, removes more than strictly necessary in many casesHigher, generalizes or suppresses only what's actually risky
Best fitStraightforward record sets, standard fields, high volumeGenomic data, longitudinal data, free text, geospatial data where Safe Harbor would destroy analytic value

What automated tooling can realistically do, and where human review still belongs

None of this means automation is the wrong approach, it means automation needs to be scoped honestly. Pattern-based and NLP-based redaction is genuinely reliable for identifiers 1 through 17, names, dates, contact details, structured numeric identifiers, because those categories are built around recognizable formats and the technology is well matched to the problem. A well-built pipeline should run entity recognition tuned specifically for PHI (not generic NER trained on news text), apply the ZIP-code population-threshold table rather than a flat truncation rule, generalize ages using the 90-or-older rule automatically, and flag device identifiers and license numbers embedded in narrative sentences rather than only in labeled fields.

Category 18 is where automation should route to human review rather than claim full coverage. A rare-condition flag (cross-referencing diagnosis codes against known prevalence data), a small-geography flag (population under a defined threshold for the described service area), and an unusual-combination flag (age plus condition plus occupation appearing together rarely in the training corpus) can all be built as signals that a document needs a second look before release, without pretending those signals alone constitute a compliant redaction. The honest architecture is layered: automate the mechanical 17 categories at high confidence, surface category-18 risk as a review flag rather than an auto-redaction, and route ambiguous narrative sections to a human reviewer who can make the contextual judgment the pattern-matcher structurally cannot.

A worked example of the population math behind category 18 risk

To make the rare-disease scenario concrete rather than abstract: if a condition affects roughly 1 in 50,000 people, and a described service area has a population of 12,000, the expected number of people in that area with that condition is 12,000 divided by 50,000, or 0.24. An expected count below 1 means that in most such areas, exactly zero or one person has the condition, so stating the diagnosis alongside even a coarse geographic reference effectively narrows the population of possible matches to a single identifiable individual in that community. This is the same logic Expert Determination formalizes with k-anonymity: a record is only safe if at least k other records in the reasonably available population share the same combination of quasi-identifiers, and a rare condition in a small area routinely fails that threshold even when k is set as low as 2. Safe Harbor's checklist doesn't compute this, it relies on the covered entity's separate "actual knowledge" obligation and the catch-all category to catch it, which only works if the humans or systems applying Safe Harbor are actually looking for it.

What to check in a document pipeline claiming Safe Harbor compliance

Ask whether the ZIP-code handling references the actual Census population data for three-digit prefixes or applies a flat rule. Ask whether date redaction runs against narrative text and relative date references, not just labeled date fields. Ask whether ages are generalized to "90 or older" automatically, and whether the underlying date fields that would let someone reconstruct that age are also suppressed. Ask what happens to rare diagnoses, unusual occupations, and other category-18 risks: are they flagged for review, or does the pipeline stop at the first 17 categories and call the job done. And if the dataset in question genuinely needs more analytic value preserved than Safe Harbor allows, ask whether anyone has actually evaluated whether Expert Determination, with a documented statistical methodology, would serve the use case better than forcing every field through the same fixed checklist. For related redaction scope questions, see our coverage of the HIPAA minimum necessary standard, which governs a related but distinct question, how much PHI to disclose for a given purpose even when full de-identification isn't the goal, and our piece on medical record release of information processing, which covers the operational workflow these redaction rules get applied inside.

The 18-identifier list is not the hard part of Safe Harbor, any compliance checklist can reprint it accurately. The hard part is the gap between identifiers that are shaped like PII and identifiers that only function as PII in context, and that gap is exactly where automated redaction pipelines built around pattern matching quietly fail while still reporting a clean pass. Knowing the actual regulatory text, the ZIP threshold, the age-90 rule, the catch-all category, and the genuine mechanical difference between a fixed checklist and a statistical risk determination is what separates a redaction tool that looks compliant from one that actually is. Written by Nupura Ughade.

Common questions

Frequently asked questions

Names, geographic subdivisions smaller than a state, all date elements except year, telephone numbers, fax numbers, email addresses, Social Security numbers, medical record numbers, health plan beneficiary numbers, account numbers, certificate or license numbers, vehicle identifiers, device identifiers, web URLs, IP addresses, biometric identifiers, full-face photographs, and any other unique identifying number, characteristic, or code, as defined under 45 CFR 164.514(b)(2)(i).

Category 18 covers information that identifies someone through context and rarity rather than format, such as a rare disease combined with a small geographic area. Pattern-based and named-entity recognition tools are built to detect identifiers with a recognizable shape, not to evaluate population-level rarity, so they correctly tag a diagnosis as a medical condition without any basis for knowing it's rare enough to function as an identifier.

Safe Harbor, under 164.514(b)(2), is a deterministic checklist: remove all 18 listed categories and you're compliant, regardless of the actual statistical re-identification risk of what remains. Expert Determination, under 164.514(b)(1), requires a qualified statistician to quantify actual re-identification risk using accepted methods and certify it is very small, which lets it evaluate combinations of quasi-identifiers, like ZIP code, age, and diagnosis together, that Safe Harbor's fixed categories can't assess jointly.

The first three digits of a ZIP code may be retained only if the geographic unit formed by all ZIP codes sharing that three-digit prefix contains more than 20,000 people. If the population is at or below that threshold, the three-digit prefix must be replaced with 000.

All date elements related to age must be removed except the year, and any age over 89, along with any date data that would let someone calculate an age over 89, must be aggregated into a single 90-or-older category, because ages that high are rare enough in a population to function as an identifier on their own.

Yes. Because Safe Harbor applies the same fixed rules regardless of a field's actual risk in context, it often strips more than a statistically grounded review would find necessary. This is the main reason organizations working with free text, genomic data, or longitudinal records sometimes choose Expert Determination instead, since it can preserve more analytic value by generalizing or suppressing only fields that are genuinely risky in combination.

Nupura Ughade

Content Marketing Lead, DocsAPI

Nupura Ughade creates clear, insightful content on OCR, document AI, and fintech. She combines technical depth with real-world finance use cases to help engineers and operations leaders navigate digital transformation with confidence.

Ready to Transform Your Lending Process?

See how DocsAPI's AI-powered industry classification can help you process loans faster, improve accuracy, and scale your operations.