Every image that appears in a web browser must be copied from the web server and written on the user’s computer. The larger the file the longer it takes to copy, or download to the user’s computer.
Optimizing an image is a method used to minimize the size of the image file so that it will load quickly in the user’s browser. If an image from a digital camera was placed on a web page without regard to its file size it would likely take a very long tome to appear on a web page. When a digital camera takes a picture it does so at a very high resolution, around 300dpi (dots per inch) or greater so that when the image is printed it will have very good detail. By contrast, images on a web site are presented on a monitor that can only display images at 72dpi. In general there is no need for a 300dpi image on a web site.
Steps to optimize an image using Photoshop:
- Open the image in Photoshop
- Edit the image if necessary.
- From the Image menu select Image Size…
- Set the Resolution to 72 pixels/inch.
- Set either the width or height to the value needed to fit in the space available on the web page where it will be placed.
- Press OK
- From the File menu select Save for Web…
- From the Settings area on the right side of the Save For Web window choose the JPEG (Joint Photographic Experts Group) format if the image is a photograph or has photographic qualities. Choose the GIF (Graphics Interchange Format) format if the image is flat and cartoon-like.
- For JPEG Images:
- Adjust the quality by selecting from the dropdown Low, Medium, High or Maximum. As you change the quality you will see the image change. If you look at the bottom left corner of the window you will see the file size and time needed for the image to appear on a user’s browser. The intent is to find a quality level where the image still looks nice but is not taking too long to download.
- After you are finished optimizing the image press Save. Save the image in the images folder of your web site.
- For GIF Images:
- From the colors dropdown select the number of colors that gives the image a decent appearance with a short download time.
- After you are finished optimizing the image press Save. Save the image in the images folder of your web site.