AnyTool
Your files never leave your device. All processing happens locally in your browser.

How do I anonymize personal data (PII) in text online for free?

Paste your text and the Data Anonymizer highlights the PII it finds — emails, phone numbers, credit cards (Luhn-checked), IPv4/IPv6, URLs, dates, IBANs (mod-97), US SSNs, India Aadhaar (Verhoeff) and PAN, plus person names — then replaces each match one of four ways: mask (j•••@e•••.com), redact to a label ([EMAIL]), consistent crypto-random pseudonyms so the same value always maps to the same fake, or a salted SHA-256 token. Toggle any entity type on or off, copy or download the result, and in pseudonym mode copy the reversal map. Everything runs in your browser; your text is never uploaded.

  • Detects 12 PII types with checksum validators (Luhn, mod-97, Verhoeff) to cut false positives
  • Four modes: mask, redact, consistent pseudonym, or salted SHA-256 hash token
  • Pseudonyms preserve joins — the same original always maps to the same fake
  • Live side-by-side original → anonymized with every match colour-coded and counted
  • 100% client-side: regex + Web Crypto in the browser, nothing uploaded

What is

Data anonymization (PII detection & replacement)

Data anonymization is the process of finding personally identifiable information (PII) in text and replacing it so individuals can no longer be identified. Redaction and masking remove or conceal a value; pseudonymization swaps it for a consistent token or fake so analytical relationships survive but the mapping can, in principle, be reversed with a key — which is why GDPR still treats pseudonymized data as personal data, whereas true anonymization does not. This tool detects common PII with regular expressions and checksum validators and replaces it locally in your browser by masking, redacting, pseudonymizing, or emitting a salted SHA-256 hash token; it is a fast privacy aid, not a certified de-identification process.

Security & Privacy

Related terms

PIIpseudonymizationredactiondata maskingtokenizationGDPRHIPAA Safe HarborLuhn checkVerhoeff checksumde-identification

Frequently Asked Questions

No. Detection and replacement happen entirely in your browser and your text never leaves your device.

The tool is 100% client-side. Detection is plain JavaScript regex plus checksum validators, pseudonyms are drawn from crypto.getRandomValues, and hash tokens are computed with the browser’s native Web Crypto (salted SHA-256) — there is no upload, no server, no CDN in the processing path and no telemetry. The pseudonym reversal map lives only in the tab’s memory and is never persisted, so closing the tab erases it. That said, because the work is local, treat the output as a first pass and review it before sharing.

Masking keeps a hint, redaction replaces with a label, pseudonyms are consistent fakes that preserve joins, and a hash is a one-way salted token.

Masking shows part of the value (last 4 of a card, j•••@e•••.com) so it stays recognisable without exposing the whole thing. Redaction replaces the value with a plain label such as [EMAIL] or [NAME]. Pseudonymization swaps each value for a consistent fake — the same original always maps to the same replacement — so relationships and joins across the document survive, and the reversal map lets you undo it. Hashing emits a salted SHA-256 token that is one-way (you cannot reverse it) but still consistent, so records can be linked without revealing the value. Pseudonymized and hashed data are still personal data under GDPR because re-identification remains possible with the key or by correlation.

Regex and heuristics have no understanding of context, and name detection is especially fuzzy.

Pattern matching is fast but imperfect. Checksum validation (Luhn for cards, mod-97 for IBAN, Verhoeff for Aadhaar) removes many false positives, but person-name detection relies on a capitalised-bigram heuristic and a common-first-name list, so it misses lowercase, single-token, non-Western or unusual names and can mislabel places, products or sentence starts. Nothing here understands meaning, so it cannot tell a home address from a shipping label or a birthday from an invoice date. Always review the highlighted output, and turn individual entity types on or off to tune detection to your text.

Treat it as a helpful first pass, not a certified de-identification pipeline.

This tool is a quick privacy aid for cleaning up logs, tickets, prompts before sending them to an LLM, screenshots and shared snippets. Formal de-identification is a higher bar: HIPAA Safe Harbor requires removing 18 specific identifier categories plus a determination of no residual re-identification risk, and GDPR pseudonymization requires documented, audited processes with securely stored keys and human review. Because regex misses PII and pseudonymized data is still personal data, do not rely on this tool alone for regulated or high-stakes data — verify every line by hand and follow your organisation’s approved process.

Detailed Explanation

How It Works

What the Data Anonymizer Does

The Data Anonymizer is a 100% client-side tool that finds personally identifiable information (PII) in free text and replaces it so people can no longer be identified. It detects twelve entity types — email addresses, phone numbers, credit-card numbers, IPv4 and IPv6 addresses, URLs, dates, IBANs, US Social Security numbers, India Aadhaar and PAN, and person names — and lets the user toggle each type on or off. Detected values are shown highlighted, colour-coded per type and counted, in a live side-by-side view of the original and the anonymized output. The user picks one of four replacement modes and can then copy or download the result, and in pseudonym mode copy a reversal map. All detection and replacement happen in the browser; the text is never uploaded.

  • Detects 12 PII entity types in free text, each individually toggleable
  • Four replacement modes: mask, redact, consistent pseudonym, salted hash token
  • Live side-by-side original vs anonymized with per-type highlighting and counts
  • Copy or download the anonymized text; copy the pseudonym reversal map
  • Everything runs locally in the browser — the text is never uploaded
Methodology

How Detection and Replacement Work

Detection combines regular expressions with checksum validators to cut false positives: credit cards must pass the Luhn (mod-10) check, IBANs the ISO 13616 mod-97 check, and Aadhaar numbers the UIDAI Verhoeff check digit, while US SSNs are filtered against never-issued ranges (area 000/666/900+, group 00, serial 0000). When two patterns overlap — for example the greedy phone matcher and a Luhn-valid card — a priority order lets the more specific entity claim its span so the card is never mangled. Replacement then runs per match: mask reveals only a hint (last 4 of a card, j•••@e•••.com), redact substitutes a label such as [EMAIL], pseudonym swaps in a consistent fake, and hash emits a salted token. A pure, fully-typed engine (dataAnonymizerEngine.ts) holds all of this logic so it is deterministic and testable, and the page only renders the highlighted segments.

  • Regex detection plus Luhn, mod-97 and Verhoeff checksum validation
  • US SSN range filtering removes obviously-invalid numbers
  • Priority-based overlap resolution: specific IDs beat the greedy phone/name matchers
  • Pure engine (dataAnonymizerEngine.ts) returns highlighted input and output segments
  • Same detection feeds all four replacement modes
Technical Details

Pseudonyms and Salted Hash Tokens

Two modes preserve joins so anonymized records stay analysable. Pseudonym mode maps each unique value to a consistent fake — the same email always becomes the same fake email — using values drawn from window.crypto.getRandomValues (never Math.random) and format-appropriate fakes seeded from reserved test ranges: 555-0100…555-0199 phone numbers, a 400000 test-card BIN with a correctly computed Luhn digit, 900-series SSNs, 203.0.113.x (TEST-NET-3) and 2001:db8:: (documentation) IP addresses, so the fakes are realistic yet clearly non-real. The tool keeps a reversal map so pseudonymization can be undone with the key. Hash mode instead computes a salted SHA-256 token with the browser’s native Web Crypto API (crypto.subtle.digest over a per-session random salt), which is one-way but still consistent, so records can be linked without exposing the value. Both are honestly labelled as still personal data under GDPR because re-identification remains possible with the key or by correlation.

  • Pseudonyms are consistent: same original always maps to the same fake
  • Fakes use crypto.getRandomValues and reserved test/documentation ranges
  • Fake cards carry a correctly computed Luhn check digit
  • Hash mode: salted SHA-256 via native Web Crypto (crypto.subtle) — one-way, consistent
  • A reversal map (pseudonym mode) lets the mapping be undone with the key
Limitations

Honest Limitations

Regex and heuristics are fast but imperfect: they will miss some PII and flag some false positives. Checksum validation removes many bad matches, but person-name detection is especially fuzzy — it relies on a capitalised-bigram heuristic and a bundled common-first-name list, so it misses lowercase, single-token, non-Western or unusual names and can mislabel place names, product names and sentence starts. The tool has no understanding of context, so it cannot tell a home address from a shipping label, a birthday from an invoice date, or a private handle from a public one. Pseudonym and hash modes preserve joins, but the pseudonym reversal map is itself sensitive, and pseudonymized data is still personal data under GDPR. This is a quick privacy aid, not a certified de-identification pipeline: HIPAA Safe Harbor (18 identifier categories) and GDPR pseudonymization require documented, audited processes and human review. For regulated or high-stakes data, treat the output as a first pass and verify every line by hand.

  • Will miss some PII and flag some false positives — always review the output
  • Name detection is heuristic and the weakest signal
  • No context awareness — cannot judge meaning or sensitivity
  • Pseudonymized/hashed data is still personal data under GDPR
  • Not a substitute for HIPAA Safe Harbor or an audited GDPR process
Privacy & Security

Private by Design

Everything happens on your device. Detection is plain JavaScript regex plus checksum validators, pseudonyms come from crypto.getRandomValues, and hash tokens are computed by the browser’s native Web Crypto — there is no network request, no upload, no logging, no server and no CDN anywhere in the processing path. The text, the highlighted segments and the pseudonym reversal map are just values in memory; nothing is persisted, added to history or synced, so closing the tab erases everything. The tool works offline once cached, supports dark mode and a mobile-first responsive layout, and has no analytics or telemetry. The only optional network use anywhere on the site is consent-gated ads, which never see your text. This matters because the whole point of anonymizing a log, a support ticket or an LLM prompt is to avoid sending raw PII somewhere else — so the cleaning itself must never round-trip through a server.

  • Detection, pseudonyms and hashing all run locally in the browser
  • No server, no CDN, no upload, no logging, no telemetry, no account
  • Nothing persisted — closing the tab erases the text and the reversal map
  • Works offline once cached; dark-mode and mobile-first
  • Only optional network use is consent-gated ads that never see the text
Replacement modes and when to use them
ModeExampleReversible?Joins preserved?Best for
Maskj•••@e•••.com, last 4 of a cardNoNoSharing a value while keeping a recognisable hint
Redact[EMAIL], [NAME]NoNoFully removing PII from a document or screenshot
Pseudonymconsistent fake email / name / cardYes, with the mapYesAnalysable data where relationships must survive
Hash token[EMAIL#a1b2c3d4e5] (salted SHA-256)NoYesLinking records one-way without revealing the value

Pseudonymized and hashed data is still personal data under GDPR because re-identification remains possible with the key or by correlation. Everything runs locally in the browser; nothing is uploaded. As of July 2026.