A usual WordPress installation has all media files stored in Media Library, and that’s where our image optimization plugin looks first. But there is not such thing as usual WordPress installation, and we all know some cases when images are stored in other places than Media Library. In this short article, we will show you how to compress those images too, using ShortPixel image optimization plugin.
We took some beautiful images from Unsplash and put them in a custom folder called extra. These images are not visible in Media Library, they are not automatically optimized on upload, and they are not accessible to our Bulk processor.
Fortunately, you could tell ShortPixel to look for images in other folders than Media Library. For this, you need to go to Settings / ShortPixel, and click on Advanced tab.
Additional media folders field will do the trick. Click Select button and choose your folder with images. In our example, it is the extra folder.
The magic is happening, and your files are being compressed by ShortPixel.
Under the Media section from your WordPress dashboard you will notice a new menu item called Other Media. Click on it and see which images not included in Media Library were optimized by ShortPixel.
Please note that you need to go to Other Media page after you upload new images in your custom folders and click Refresh folders button.
You could use the same approach for optimizing images in themes or plugins, or images from folders created by image gallery plugins or you could simply use WordPress as image optimization platform.
Compress files and generate WebP images
Please note that you can also choose to have WebP version of the files generated by ShortPixel when optimizing these images in your extra folders.
The option is in ShortPixel Settings – Advanced section:
If you don’t know what WebP files are and why they are good for your site, here are a few references:
– Google: A new image format for the Web
– WikiPedia: WebP
– ShortPixel blog: How WebP images can speed up your (WordPress) site
You could find a lot of quality documentations about WebP format, but these links are a good start.
Install ShortPixel and optimize images outside WP Media Library
Now that you know how to compress images which are not stored in your WordPress Media Library, and speed up your site even more, go ahead and install ShortPixel! 🙂