Wordpress LScache Plugin: WebP image replacement for subdomain image URLs
Last Updated on: Wed, 15 Apr 2026 00:00:02 Hi! I love your products, but Ive been having trouble getting WebP image replacement to work for a few sites that serve their images from a subdomain ? e.g. img.domain.com. The images are located in a subfolder of the main domain (domain.com/img/?) and the images within the subfolder are redirected to the subdomain img.domain.com/image-file. This structure is left over from the days when parallel downloading was beneficial. For SEO reasons, Im not excited about moving the images to the standard /wp-content/uploads folders, but as a last resort, I may do that and used redirects for older images. Anyway, Im wondering if there is a way to get the litespeed wordpress cache plugin WebP replacement function to work for my setup with images served from the img.domain.com subdomain. Ive had several tickets open for this issue via the support tickets on your website, but to date, it seems to have those working with me baffled. I wont think this is too complicated, just serving images from a different folder? It was suggested and I have tried adding the img.domain subdomain to the CDN function in an attempt to have LSWPC recognize the subdomain, but it hasnt seemed to work so far. I also tried re-optimizing all of my prior images and see that most images do have a jpg.webp version. Any help would be greatly appreciated or recommendation for third party help. ThanksThis topic was modified 2 years, 1 month ago by gzupfer. The page I need help with: http://modernprefabs.com Hi, for the record the issue was solved by add define( LITESPEED_WP_REALPATH, /img ) to wp-config.php to adapt to users unique site/file structure. Best regards,
LiteCache Rush: Speed comes from using less, not from doing it faster
Reference