If you are not sure how to optimize images for the web, we got you covered. Users want to see pictures on your website because they respond better to images than they do to text.
When you have quality and business fitting images on your site, they do much more than attract more visitors to your site. They also improve your search rankings in both web and image search results.
However, if you do not optimize the images on your website, it will take a very long time to load. And a slow loading website means higher bounce rates (this means that visitors will quickly leave the website after viewing the landing page), and lower search engine ranking.
If you would like to learn more about website page speed, you are welcome to read our page speed optimization guide.
In this article, we will teach you how to optimize images for the web without losing quality and file types you should use.
- What is image optimization?
- 4 main reasons why you should optimize your images
- How to optimize images for the web without losing quality
What Is Image Optimization?
Image optimization means resizing and compressing large image files to the smallest possible size, dimension, and format without losing image quality.
4 Main Reasons Why You Should Optimize Your Images For Web
When you upload original images with large file sizes to your website:
- they will take up large amounts of memory on the server
- the browser will need a lot of time and bandwidth to download them
- your website will load very slowly, resulting in a poor user experience
- Your website will experience a high bounce rate, low conversion rate, and low search engine ranking.
How To Optimize Images For The Web Without Losing Quality
To optimize images for the web, you have to alter the images in such a way that the size is reduced, but the image appears sharp and clear across all devices. The next steps will teach you the various ways to do this.
Use Image Optimization Plugins For WordPress
With image optimization plugins in WordPress, you can automatically optimize images as they are uploaded to your site. These plugins usually work by compressing your image files for optimal web performance. One great plugin for this purpose is Smush Image Compression and Optimization.
Install this plugin in your site to enable automatic image compression and optimization. Learn how to install WordPress plugins here.
Here are some other Image Optimization plugins you can choose from:
- Short Pixel Image Optimizer
- Compress JPEG & PNG
Choose The Right File Formats For Raster Images
Raster images are pixel-based graphics. Generally, the files we save in .png and .jpg format are raster images. Depending on the performance you desire, it is important to choose the best file format in this category.
- JPEG(Joint Photographic Experts Group): Files in this format are usually smaller in size than other formats, so if you aim for the smallest sizes, this is the right format for you. However, JPG images can lose some of their quality when compressed, so you may sacrifice quality when saving with this format.
- PNG(Portable Network Graphics): PNG files can be effectively compressed without losing quality. They are however generally larger than jpeg files. Files in this format are transparent and are suitable for small images.
- GIF(Graphics Interchange Format): GIFs can only be losslessly compressed and are a good choice for animation graphics. This file format should be used minimally as they are generally larger.
Rescale Dimensions To Reduce Image Size and Optimize Image for Web
Here’s how to save images for web and optimize in Adobe Photoshop:
- Go to image and press adjust size. A popup will appear, make sure width and height are ticked so it doesn’t scale the image in an unbalanced way.
- Next, click “save for web“. Here you can select your image’s file type such as GIF, PNG or JPEG format.
Here’s how to reduce image size in Ribbet:
- Change the image dimensions to what you require without altering the proportions. In this case, we reduced our image from 2805 X 1863 to 860 x 571.
- Click on Apply, then save the changes made to the image before uploading it to the web.
Compress Images To Reduce File Size
In order to effectively optimize an image for the web, you have to reduce its file size. The higher the file size, the higher the image quality, but the more memory it consumes on the server. The size of an image can be noticeably reduced by compressing the image file in two ways:
- Lossy compression: This means completely removing some information that came with the original image which is not very important.
- Lossless compression: This means the image file will be reduced without removing any information that came with the original file.
A photo editing software such as the Microsoft Picture Manager or Adobe Photoshop can be used to manually compress the image, and specialized tools such as ‘ImageKit’, ‘compressjpeg’ or ‘compresspng’ can also be used to automatically optimize and save the image for the web.
To use these tools simply drag & drop your images or press upload button.
- Compress JPEG example. As you can see in the image below, basic optimization saved 47% and decreased the size to 81kb.
Also, make sure you don’t decrease quality settings too much as it will make the image look blurry.
- Compress PNG example. This time we managed to save 71% and decrease size to 133kb. We suggest around 100kb file size or under.
With this tool, you can also upload multiple images. This tool adds -min extension to your file name so make sure you remove that after you save your images and upload them to your website.
Here is an example of a compressed and resized image:
Original image having a file size of 447KB
Compressed image having a file size of 33KB
Serve Images From a Content Delivery Network
Another great way to optimize images and site speed is to serve your images to users through a Content Delivery Network (CDN).
Content Delivery Networks serve your cached images to users from their network of globally distributed proxy servers. They employ real-time image optimization by loading images from their cache/proxy servers which are geographically closest to the users. This offers users a fast loading experience as the burden of serving images is taken away from your server. Content delivery networks also use device detection to determine the size and format of the image it should render to separate devices. Some of the content delivery networks you may consider are Incapsula, imgix, and ImageEngine.
Consider Using Vector Images to Optimize Images for Web
Scalable vector graphics (SVG) are images that can scale to infinite screen resolutions without losing image quality. Vector images are suitable for the web because they enhance web page speed. You can easily add them to the web page as responsive images.
The SVG file format is not good for detailed images such as digital photography and painting. However, it is best suited for graphics that display shapes, curved lines, and colors (e.g. icons, logos, and illustrations).
This guide has shown you how to optimize images for the web. Our image optimization tools have different uses and options. Some will allow you to resize images and decrease image size, and some, on the other hand, can optimize your uploaded images if you are on WordPress.
If you follow the steps covered, you would be able to display quality images to your users without slowing down your website, or filling your storage. More importantly, you will enjoy the SEO benefits that come from having good images, while avoiding the SEO penalization that comes from large images slowing down your site.
You can also test your page with Google’s pagespeed insights to make sure you properly optimized your images and page for fast loading speed.
If you have used other image optimization steps that worked great for you, please share them with our readers in the comments below.