Remove Event Handlers From SVG

Strip onclick and other event-handler attributes

Sanitize SVG? Sanitize SVGRemove scripts? Remove scripts

FAQ

Quick answers

Which SVG event handlers get removed?
Common on* attributes such as onclick, onload, and onmouseover are stripped.
Do I still need to remove script tags separately?
Yes. Pair with Remove Scripts for a fuller sanitize pass, or use Sanitize SVG Online.
Will removing handlers break my animation CSS?
No. CSS and SMIL animations unrelated to on* attributes stay.
Does handler removal require uploading the SVG?
No — free browser tool with local processing.
Sanitize SVG → Remove scripts → Remove embedded HTML → Remove unused elements →
Open full editor →

Source

Type or paste SVG markup. The preview on the right updates as you type.

Ready

Live preview

PNG export · 2× for retina