Image Manipulation in Linux and Mac Convert an image to webp format Install webp utility using Linux package manager or Homebrew in Mac. cwebp -q quality (optional) input-image.jpg -o output-image.webp # where quality is between 0 (poor) to 100 (very good). # Typical value is around 80.