Hello @issacchua
Thank you for reaching out and I am happy to assist you with this.
Can you please clarify the “Compression”? Do you want to convert images to webp or simply compress images to a smaller size?
I am asking this because the W3 Total cache has the Image Service Extension in Performance Extensions, which converts the images to webp.
If you are not planning to do this, all major image optimization plugins are compatible with W3 Total Cache, like SmushIt, or Ewww image optimization.
As for hosting the images on the CDN, No plugin can optimize or compress the images that are already on the CDN. This being said, once compressed or optimized, you will need to purge the CDN cache in order for the new optimized images to be uploaded and served from the CDN.
I hope this helps!
Thanks!
Hi Marko,
Thanks for your reply. I am looking to decrease the image size is what I meant by compression. If converting to webp works, I won’t mind getting that.
No plugin can optimize or compress the images that are already on the CDN. This being said, once compressed or optimized, you will need to purge the CDN cache in order for the new optimized images to be uploaded and served from the CDN.
I am currently using W3 Total Cache CDN option so that images are offloaded to CDN. If using Image Service Extension, does the webp file will store on the S3 as well (same path as the regular image that is uploaded to S3), and that the WordPress will simply load the webp resource rather than the image resource from CDN?
Hello @issacchua
Thank you for your feedback.
The images are optimized on your server, and once optimized, they need to be uploaded (replaced) on the CDN since W3 Total Cache does not delete any images if they are converted or uploaded to the CDN.
So again, if the images are served from the CDN, once the conversion is done, the CDN needs to be purged.
If the images are served from the origin, then the conversion is automatic.
I hope this answers your question.
Thanks!
Hi Marko,
To clarify, when I convert the image on my server, it will automatically upload (and replace) the image on origin (in my case, S3 from AWS).
If we don’t send the invalidate request to CDN (in my case, Cloudfront from AWS), then the Cloudfront will continue to serve the image from its cache version (the original image that is cached in Cloudfront) until the cache version is expired.
Is my understanding correct? Thanks!
Hello @issacchua
Yes, that is correct. the AWS cache needs to be invalidated in order to serve converted mages.
Thanks!
Ok, thanks for your response!