DOMPurify

DOMPurify - a DOM-only, super-fast, uber-tolerant XSS sanitizer for HTML, MathML and SVG. DOMPurify works with a secure default, but offers a lot of configurability and hooks. Demo:

Recent spike, 1.4× faster than Developer Tooling this week

7d +0.11% +19 stars in 7d
30d Not tracked yet — first tracked 2026-09-08
90d Not tracked yet — first tracked 2026-09-08
Sep 8, 2026: 17,367 starsSep 9, 2026: 17,369 starsSep 10, 2026: 17,373 starsSep 11, 2026: 17,377 starsSep 12, 2026: 17,379 starsSep 13, 2026: 17,383 starsSep 14, 2026: 17,385 starsSep 15, 2026: 17,390 starsSep 16, 2026: 17,394 starsSep 17, 2026: 17,397 starsSep 18, 2026: 17,402 starsSep 19, 2026: 17,405 starsSep 20, 2026: 17,406 starsSep 21, 2026: 17,409 starsSep 22, 2026: 17,409 starsSep 23, 2026: 17,408 starsSep 24, 2026: 17,409 starsSep 25, 2026: 17,411 starsSep 26, 2026: 17,413 starsSep 27, 2026: 17,413 starsSep 28, 2026: 17,417 starsSep 29, 2026: 17,421 starsSep 30, 2026: 17,423 starsOct 1, 2026: 17,428 stars 17,36717,39817,428 Sep 8Oct 1

17,367 → 17,428 stars since Sep 8

17,363 Stars 861 Forks 0 Open issues
cross-site-scriptingdomdompurifyhtmljavascriptmathmlprevent-xss-attackssanitizersecuritysvgxss