GIMP is a awesome image editor, but more functionality can be achieved by adding some plugins to it. Image optimization can be huge pain sometimes if you have to optimize your image for your website/blog/web application. Images with size of >40KB are recommended for use in websites, because they load fast, takes less bandwidth and better user experience.
Save for web is a GIMP plugin that optimizes and compress your image for using it in websites. You can choose the image quality and if quality is lesser then image size is also less.
If you do not have GIMP (image editor) installed, then you should first install GIMP(step by step installation guide) and then follow these steps:
Step 1: Download save for web GIMP plugin for Mac OS X, and double click the zip file to extract it.
Step 2: Press “F4”, and open “Terminal”
Step 3: Type this command
sudo mv path_to_webexport ~/Library/Application\ Support/GIMP/plug-ins/
In my case the webexport file was in “Downloads” folder and I had GIMP 2.8 installed so I ran the follwing command.
sudo mv Downloads/webexport ~/Library/Application\ Support/GIMP/2.8/plug-ins/
Now restart your GIMP and you can find option to save images for web by going to “File->save for web”