How to batch convert JPG images to progressive JPG images?

Progressive JPG images, as opposed to baseline JPG, will display right away in the browser, and will load bits of it in cycle, rendering it from blur to clear.

Progressive is known to provide a better user experience, preventing the ”fax loading” effect. Where the image is displayed in full, but sequentially from top to bottom.

The imagemagick package will install the convert command that you can run to convert JPG to progressive:

convert -strip -interlace Plane -quality 80 input-file.jpg output-file.jpg

From there, it only takes a simple bash loop to batch convert several images at once:

for image in *.jpg; do
convert -strip -interlace Plane -quality 75 $image $image;
Like what you read? Give Julien Buty a round of applause.

From a quick cheer to a standing ovation, clap to show how much you enjoyed this story.