How to speedup your WordPress website by compressing jpeg images in Linux CentOS using jpegoptim

by Mar 15, 2020Linux, Software, Wordpress0 comments

How to speedup your WordPress website by compressing jpeg images in Linux CentOS using jpegoptim

Is your  website running slow? Reducing the size of the images will speed it up and you will get higher ranking in Google and other search engines.

In this video, I show you how to speedup your WordPress website by compressing jpeg images in Linux CentOS using jpegoptim.

Commands:

yum install epel-release

yum install jpegoptim

  • To optimize all JPEG pictures recursively (In sub-folders):

find -type f -name “*.jpg” -exec jpegoptim -p {} \; To compress all JPEG pictures in one folder: jpegoptim -p *.jpg

  • To schedule the command in a cron job, put the path you want right after find:

find /home -type f -name “*.jpg” -exec jpegoptim -p {} \;

Note:  Use the above instructions at your own risk and always backup your images before performing any of these commands in case something goes wrong.

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

Follow Me

Website created with DIVI. Get 10% discount with link below

Divi WordPress Theme Affiliate link

Recent Comments

    Stay Up to Date With The Latest News & Updates

    Join Our Newsletter

    Share This