How To Add SVG Upload Support To WordPress

How To Add SVG Upload Support To WordPress

By default, WordPress wouldn’t let you upload SVG files through the media uploader. However, a little piece of code will solve this problem for you. Just add following code to your theme’s functions.php file:

Above snippet would work like a charm. However, it displays huge wherever it gets displayed in WordPress Admin, so add following code to your function.php to fix this problem: