A DOM-only, super-fast, uber-tolerant XSS sanitizer for HTML, SVG and MathML. It's also very simple to use and get started with. DOMPurify was started in February 2014 and, meanwhile, has reached version 2.3.0. DOMPurify is written in JavaScript and works in all modern browsers (Safari (10+), Opera (15+), Internet Explorer (10+), Edge, Firefox and Chrome - as well as almost anything else using Blink or WebKit). It doesn't break on MSIE6 or other legacy browsers. It either uses a fall-back or simply does nothing. Our automated tests cover 17 different browsers right now, more to come. We also cover Node.js v14.15.1, v15.4.0, running DOMPurify on jsdom. Older Node.js versions are known to work as well. DOMPurify is written by security people who have vast background in web attacks and XSS.

Features

  • DOMPurify sanitizes HTML and prevents XSS attacks
  • You can feed DOMPurify with string full of dirty HTML and it will return a string (unless configured otherwise) with clean HTML
  • DOMPurify will strip out everything that contains dangerous HTML
  • Prevents XSS attacks and other issues
  • The faster your browser, the faster DOMPurify will be
  • Just include DOMPurify on your website

Project Samples

Project Activity

See All Activity >

Categories

HTML/XHTML

License

Apache License V2.0, Mozilla Public License 2.0 (MPL 2.0)

Follow DOMPurify

DOMPurify Web Site

You Might Also Like
Red Hat Ansible Automation Platform on Microsoft Azure Icon
Red Hat Ansible Automation Platform on Microsoft Azure

Red Hat Ansible Automation Platform on Azure allows you to quickly deploy, automate, and manage resources securely and at scale.

Deploy Red Hat Ansible Automation Platform on Microsoft Azure for a strategic automation solution that allows you to orchestrate, govern and operationalize your Azure environment.
Rate This Project
Login To Rate This Project

User Reviews

Be the first to post a review of DOMPurify!

Additional Project Details

Programming Language

JavaScript

Related Categories

JavaScript HTML XHTML

Registered

2021-08-09