{"id":14743,"date":"2026-03-24T18:07:05","date_gmt":"2026-03-24T16:07:05","guid":{"rendered":"https:\/\/shortpixel.com/blog\/?p=14743"},"modified":"2026-03-24T18:07:15","modified_gmt":"2026-03-24T16:07:15","slug":"shortpixel-cdn-amazon-s3-on-the-fly-image-optimization-setup-guide","status":"publish","type":"post","link":"https:\/\/shortpixel.com\/blog\/shortpixel-cdn-amazon-s3-on-the-fly-image-optimization-setup-guide\/","title":{"rendered":"ShortPixel CDN + Amazon S3: On-the-Fly Image Optimization Setup Guide"},"content":{"rendered":"\n<p>If you store images in Amazon S3, chances are you&#8217;re paying more for bandwidth than you should.<\/p>\n\n\n\n<p>Every time someone requests an image, S3 serves the original, full resolution, uncompressed, in whatever format you uploaded. No resizing for mobile. No conversion to WebP or AVIF. Just the raw file, every single time.<\/p>\n\n\n\n<p>Multiply that by thousands of requests and it adds up fast.<\/p>\n\n\n\n<p>The fix? Put ShortPixel CDN between your S3 bucket and your users. It fetches the original once, optimizes it on the fly, caches it globally, and serves the lighter version from the nearest edge. Your originals stay untouched.<\/p>\n\n\n\n<p>In this guide, we&#8217;ll walk through the full setup, from creating the S3 bucket to serving optimized images through ShortPixel CDN.<\/p>\n\n\n\n<div class=\"wp-block-group has-border-color has-palette-color-8-background-color has-background is-layout-constrained wp-container-core-group-is-layout-239228e0 wp-block-group-is-layout-constrained\" style=\"border-color:#888888;border-width:1px;border-radius:20px;padding-top:var(--wp--preset--spacing--60);padding-right:var(--wp--preset--spacing--60);padding-bottom:var(--wp--preset--spacing--60);padding-left:var(--wp--preset--spacing--60)\">\n<div class=\"wp-block-group is-nowrap is-layout-flex wp-container-core-group-is-layout-6c531013 wp-block-group-is-layout-flex\">\n<div class=\"wp-block-outermost-icon-block\"><div class=\"icon-container\" style=\"width:25px;transform:rotate(0deg) scaleX(1) scaleY(1)\"><svg xmlns=\"http:\/\/www.w3.org\/2000\/svg\" id=\"Layer_1\" viewBox=\"0 0 90.96 101.06\"><defs><style>.cls-1{fill:#efcc08;}<\/style><\/defs><path d=\"m53.54,79.72h-16.25c-1.48,0-2.68-1.2-2.68-2.68v-1.88c.02-1.62-.06-2.75-.23-3.39-.91-3.34-3.33-6.14-5.66-8.86-.77-.89-1.5-1.74-2.17-2.59-3.36-4.28-5.15-9.41-5.15-14.85,0-13.28,10.81-24.08,24.09-24.08s24.08,10.8,24.08,24.08c0,5.44-1.78,10.58-5.15,14.85-.59.76-1.27,1.55-1.98,2.39-2.39,2.82-5.07,5.96-5.99,9.28-.16.59-.24,1.66-.23,3.15v1.9c0,1.48-1.19,2.68-2.67,2.68h0Z\"><\/path><path class=\"cls-1\" d=\"m39.97,74.36h10.89c.03-2.08.23-3.11.42-3.78,1.24-4.47,4.32-8.1,7.03-11.28.71-.84,1.34-1.57,1.89-2.27,2.62-3.33,4.01-7.32,4.01-11.55,0-10.33-8.4-18.73-18.72-18.73s-18.73,8.4-18.73,18.73c0,4.22,1.38,8.21,4.01,11.54.62.79,1.3,1.57,2.02,2.4,2.47,2.87,5.54,6.43,6.78,10.95.18.71.39,1.78.42,3.99h0Z\"><\/path><path d=\"m53.54,90.34h-16.25c-1.48,0-2.68-1.2-2.68-2.68s1.19-2.67,2.68-2.67h16.25c1.48,0,2.67,1.19,2.67,2.67s-1.19,2.68-2.67,2.68h0Z\"><\/path><path d=\"m49.48,101.06h-8.12c-1.48,0-2.68-1.2-2.68-2.68s1.2-2.68,2.68-2.68h8.12c1.47,0,2.68,1.2,2.68,2.68s-1.2,2.68-2.68,2.68h0Z\"><\/path><path d=\"m88.29,48.16h-10.7c-1.48,0-2.68-1.19-2.68-2.68s1.2-2.68,2.68-2.68h10.7c1.48,0,2.67,1.2,2.67,2.68s-1.19,2.68-2.67,2.68h0Z\"><\/path><path d=\"m13.38,48.16H2.67c-1.48,0-2.67-1.19-2.67-2.68s1.19-2.68,2.67-2.68h10.7c1.48,0,2.68,1.2,2.68,2.68,0,1.48-1.2,2.68-2.68,2.68h0Z\"><\/path><path d=\"m45.48,16.06c-1.48,0-2.68-1.19-2.68-2.68V2.68c0-1.48,1.2-2.68,2.68-2.68s2.68,1.2,2.68,2.68v10.7c0,1.48-1.19,2.68-2.68,2.68h0Z\"><\/path><path d=\"m75.74,78.42c-.68,0-1.36-.26-1.89-.79l-7.57-7.57c-1.04-1.04-1.04-2.74,0-3.79,1.05-1.04,2.74-1.04,3.78,0l7.57,7.57c1.05,1.05,1.05,2.75,0,3.79-.52.53-1.2.78-1.9.78h0Z\"><\/path><path d=\"m22.77,25.46c-.68,0-1.37-.26-1.9-.79l-7.56-7.56c-1.05-1.05-1.05-2.75,0-3.79,1.05-1.04,2.74-1.04,3.78,0l7.57,7.57c1.05,1.04,1.05,2.75,0,3.79-.52.53-1.21.79-1.9.79h0Z\"><\/path><path d=\"m15.21,78.42c-.68,0-1.37-.26-1.89-.78-1.05-1.04-1.05-2.74,0-3.79l7.57-7.57c1.04-1.04,2.73-1.04,3.78,0,1.05,1.05,1.05,2.75,0,3.79l-7.57,7.57c-.53.52-1.21.78-1.89.78h0Z\"><\/path><path d=\"m68.18,25.46c-.68,0-1.37-.26-1.9-.79-1.04-1.04-1.04-2.74,0-3.78l7.57-7.57c1.04-1.04,2.74-1.05,3.78,0,1.05,1.05,1.05,2.74,0,3.79l-7.56,7.56c-.52.53-1.21.79-1.9.79h0Z\"><\/path><\/svg><\/div><\/div>\n\n\n\n<p class=\"has-medium-font-size\"><strong>Quick Takeaways<\/strong><\/p>\n<\/div>\n\n\n\n<ul class=\"wp-block-list\">\n<li>S3 is built for storage, not image delivery, it serves raw files with no compression, resizing, or format conversion.<\/li>\n\n\n\n<li>ShortPixel CDN optimizes S3 images on the fly via URL parameters, no SDKs or Lambda functions needed.<\/li>\n\n\n\n<li>The setup covers creating an S3 bucket, IAM policy and user, connecting to ShortPixel, and building optimized URLs.<\/li>\n\n\n\n<li>For WordPress sites with S3 media, the ShortPixel Adaptive Images (SPAI) plugin automates the entire process.<\/li>\n\n\n\n<li>Image payloads typically drop by 40\u201380% with compression and next-gen format delivery.<\/li>\n<\/ul>\n<\/div>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Why serving raw images from S3 is a problem<\/strong><\/h2>\n\n\n\n<p>S3 is great for storage. Reliable, cheap per GB, and it scales without you thinking about it.<\/p>\n\n\n\n<p>But it&#8217;s not an image delivery service.<\/p>\n\n\n\n<p>When you serve images directly from S3, or even through CloudFront without a transformation layer, you&#8217;re dealing with a few issues:<\/p>\n\n\n\n<p><strong>No compression.<\/strong> That 4MB DSLR photo or product image gets delivered at full weight, every time.<\/p>\n\n\n\n<p><strong>No format negotiation.<\/strong> Visitors get the original JPEG or PNG, even when their browser supports<a href=\"https:\/\/shortpixel.com\/blog\/avif-vs-webp\/\"> AVIF<\/a> at a fraction of the size.<\/p>\n\n\n\n<p><strong>No resizing.<\/strong> A 3000px-wide image gets downloaded by mobile users who only need 400px. This is one of the most common reasons for <a href=\"https:\/\/shortpixel.com\/blog\/properly-size-images-for-websites\/\">failing the &#8220;properly size images&#8221; audit<\/a> in tools like PageSpeed Insights.<\/p>\n\n\n\n<p><strong>Bandwidth costs stack up.<\/strong> AWS charges for every byte transferred out of S3. Serving unoptimized images makes this way more expensive than it needs to be.<\/p>\n\n\n\n<p>Now, you <em>could<\/em> build your own pipeline with Lambda + Sharp + CloudFront. It works. But that&#8217;s infrastructure you have to build, deploy, monitor, and maintain. And Lambda cold starts can add noticeable latency on the first request.<\/p>\n\n\n\n<p>There&#8217;s a simpler path: let a URL-based CDN handle it for you.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>How ShortPixel CDN optimization works<\/strong><\/h2>\n\n\n\n<p>The idea is straightforward. Instead of pointing your &lt;img&gt; tags at the raw S3 URL, you point them at a ShortPixel CDN URL that includes optimization instructions.<\/p>\n\n\n\n<p><strong>Raw S3 URL (no optimization):<\/strong><\/p>\n\n\n\n<p><a href=\"https:\/\/my-bucket.s3.eu-central-1.amazonaws.com\/uploads\/hero.jpg\" target=\"_blank\" rel=\"noopener\">https:\/\/my-bucket.s3.eu-central-1.amazonaws.com\/uploads\/hero.jpg<\/a><\/p>\n\n\n\n<p><strong>Through ShortPixel CDN (resized, compressed, auto-format):<\/strong><\/p>\n\n\n\n<p><a href=\"https:\/\/cdn.shortpixel.ai\/xcf\/w_1200+q_lossy+ret_img+to_auto\/my-bucket.s3.eu-central-1.amazonaws.com\/uploads\/hero.jpg\" target=\"_blank\" rel=\"noopener\">https:\/\/cdn.shortpixel.ai\/xcf\/w_1200+q_lossy+ret_img+to_auto\/my-bucket.s3.eu-central-1.amazonaws.com\/uploads\/hero.jpg<\/a><\/p>\n\n\n\n<p>Here&#8217;s what each part does:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>cdn.shortpixel.ai \u2014 ShortPixel&#8217;s CDN endpoint<\/li>\n\n\n\n<li>xcf \u2014 your account-specific identifier (visible in the ShortPixel dashboard after setup)<\/li>\n\n\n\n<li>w_1200+q_lossy+ret_img+to_auto \u2014 optimization parameters, chained with +<\/li>\n\n\n\n<li>Everything after the parameters \u2014 the original S3 path, without https:\/\/<\/li>\n<\/ul>\n\n\n\n<p>The CDN reads the parameters, fetches the original from S3, applies the transformations, caches the result, and serves it. Next time someone requests the same image with the same parameters, it comes straight from cache. No round-trip to S3.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>A quick note on URL path differences<\/strong><\/h3>\n\n\n\n<p>You might notice that ShortPixel uses different URL paths depending on the image source.<\/p>\n\n\n\n<p>For regular website images (served from your own domain), the CDN URL includes \/spai\/:<\/p>\n\n\n\n<p><a href=\"https:\/\/cdn.shortpixel.ai\/spai\/w_800+q_lossy+ret_img\/mysite.com\/wp-content\/uploads\/photo.jpg\" target=\"_blank\" rel=\"noopener\">https:\/\/cdn.shortpixel.ai\/spai\/w_800+q_lossy+ret_img\/mysite.com\/wp-content\/uploads\/photo.jpg<\/a><\/p>\n\n\n\n<p>For S3-sourced images, \/spai\/ is dropped and the account identifier appears directly:<\/p>\n\n\n\n<p><a href=\"https:\/\/cdn.shortpixel.ai\/xcf\/w_800+q_lossy+ret_img\/my-bucket.s3.amazonaws.com\/uploads\/photo.jpg\" target=\"_blank\" rel=\"noopener\">https:\/\/cdn.shortpixel.ai\/xcf\/w_800+q_lossy+ret_img\/my-bucket.s3.amazonaws.com\/uploads\/photo.jpg<\/a><\/p>\n\n\n\n<p>This tells the CDN backend that the source is an S3 bucket. It uses this to know when to strip the S3 hostname from the URL, important both for correct caching and for keeping your bucket details hidden from end users (especially with private buckets).<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Available optimization parameters<\/strong><\/h2>\n\n\n\n<p>Here are the parameters you can use when building your CDN URLs:<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td><strong>Parameter<\/strong><\/td><td><strong>What it does<\/strong><\/td><\/tr><tr><td>w_800<\/td><td>Resize width to 800px (keeps aspect ratio but can be changed to a different size)<\/td><\/tr><tr><td>h_600<\/td><td>Resize height to 600px (keeps aspect ratio but can be changed to a different size)<\/td><\/tr><tr><td>q_lossy<\/td><td>Lossy compression, smallest file size<\/td><\/tr><tr><td>q_glossy<\/td><td>Glossy, good balance of quality and size<\/td><\/tr><tr><td>q_lossless<\/td><td>Lossless, no quality loss<\/td><\/tr><tr><td>to_auto<\/td><td>Serve AVIF or WebP based on browser support<\/td><\/tr><tr><td>ret_img<\/td><td>Return the image directly<\/td><\/tr><tr><td>ret_wait<\/td><td>Wait for processing before returning<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>Chain them with +:<\/p>\n\n\n\n<p>w_1200+q_glossy+ret_img+to_auto<\/p>\n\n\n\n<p>With to_auto, ShortPixel checks the browser&#8217;s Accept header. AVIF-capable browsers get AVIF. WebP-capable ones get WebP. Everything else gets the original format.<\/p>\n\n\n\n<p>Not sure which compression level to pick? Here&#8217;s a quick breakdown: <strong>Lossy<\/strong> gives you the smallest files with barely noticeable quality loss, great for most web images. <strong>Glossy<\/strong> preserves more detail and works well for photography or product images. <strong>Lossless<\/strong> keeps the image pixel-identical to the original.<\/p>\n\n\n\n<p>This alone typically cuts image payloads by 50\u201390%, depending on the originals.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Step-by-step setup<\/strong><\/h2>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Step 1: Create your Amazon S3 bucket<\/strong><\/h3>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Step 2: Connect the bucket in the ShortPixel dashboard<\/strong><\/h3>\n\n\n\n<p>With your S3 bucket and IAM credentials ready, head to ShortPixel.<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li>Log in to your<a href=\"https:\/\/shortpixel.com\/dashboard\"> ShortPixel account<\/a>.<\/li>\n\n\n\n<li>Go to <strong>Associate Domains<\/strong>. Add your domain if it&#8217;s not there yet, then click the <strong>Settings<\/strong> (gear) icon next to it.<\/li>\n\n\n\n<li>Click <strong>Storage<\/strong> and choose <strong>Amazon S3<\/strong> from the dropdown.<\/li>\n\n\n\n<li>Fill in the fields<\/li>\n\n\n\n<li>Save. ShortPixel will generate a <strong>base CDN URL<\/strong> for your bucket: https:\/\/cdn.shortpixel.ai\/xcf<\/li>\n<\/ol>\n\n\n\n<p>Your specific identifier shows up in the dashboard. Keep this URL, you&#8217;ll need it to build image URLs.<\/p>\n\n\n\n<figure class=\"wp-block-image aligncenter size-large\"><a href=\"https:\/\/shortpixel.com/blog\/wp-content\/uploads\/2026\/03\/amazon-s3-setup.png\"><img decoding=\"async\" width=\"1024\" height=\"657\" src=\"https:\/\/shortpixel.com/blog\/wp-content\/uploads\/2026\/03\/amazon-s3-setup-1024x657.png\" alt=\"\" class=\"wp-image-14752\" title=\"\" srcset=\"https:\/\/shortpixel.com\/blog\/wp-content\/uploads\/2026\/03\/amazon-s3-setup-1024x657.png 1024w, https:\/\/shortpixel.com\/blog\/wp-content\/uploads\/2026\/03\/amazon-s3-setup-300x192.png 300w, https:\/\/shortpixel.com\/blog\/wp-content\/uploads\/2026\/03\/amazon-s3-setup-768x492.png 768w, https:\/\/shortpixel.com\/blog\/wp-content\/uploads\/2026\/03\/amazon-s3-setup.png 1488w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><\/a><\/figure>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Step 3: Use your optimized image URLs<\/strong><\/h3>\n\n\n\n<p>That&#8217;s it for setup. Now you just build the URL.<\/p>\n\n\n\n<p>Append optimization parameters and the original S3 path to your base CDN URL:<\/p>\n\n\n\n<p><a href=\"https:\/\/cdn.shortpixel.ai\/xcf\/w_1200+q_lossy+ret_img+to_auto\/my-bucket.s3.eu-central-1.amazonaws.com\/uploads\/photo.jpg\" target=\"_blank\" rel=\"noopener\">https:\/\/cdn.shortpixel.ai\/xcf\/w_1200+q_lossy+ret_img+to_auto\/my-bucket.s3.eu-central-1.amazonaws.com\/uploads\/photo.jpg<\/a><\/p>\n\n\n\n<p>Use it wherever you&#8217;d normally use an image URL \u2014 HTML, CSS, JavaScript, API responses:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>&lt;img\n\n\u00a0\u00a0src=\"https:\/\/cdn.shortpixel.ai\/xcf\/w_1200+q_lossy+ret_img+to_auto\/my-bucket.s3.eu-central-1.amazonaws.com\/uploads\/photo.jpg\"\n\n\u00a0\u00a0alt=\"Optimized product image\"\n\n\/><\/code><\/pre>\n\n\n\n<pre class=\"wp-block-code\"><code>.hero {\n\n\u00a0\u00a0background-image: url('https:\/\/cdn.shortpixel.ai\/xcf\/w_1920+q_glossy+ret_img+to_auto\/my-bucket.s3.eu-central-1.amazonaws.com\/assets\/bg.jpg');\n\n}<\/code><\/pre>\n\n\n\n<p>No SDK. No build step. Just a URL swap.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Private buckets<\/strong><\/h3>\n\n\n\n<p>If your bucket isn&#8217;t public, no problem. The AWS credentials in the ShortPixel dashboard handle authentication server-side.<\/p>\n\n\n\n<p>ShortPixel fetches the image on your behalf, and the S3 hostname gets stripped from the final CDN URL, so your bucket details stay hidden from end users. From the visitor&#8217;s side, the image just comes from cdn.shortpixel.ai.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>WordPress: Setting up SPAI with Amazon S3<\/strong><\/h2>\n\n\n\n<p>Running WordPress with media stored on S3? The <strong>ShortPixel Adaptive Images (SPAI)<\/strong> plugin automates the whole URL rewriting process for you.<\/p>\n\n\n\n<p>After connecting your bucket in the ShortPixel dashboard (Step 2 above), you configure <a href=\"https:\/\/shortpixel.com\/knowledge-base\/article\/using-shortpixel-adaptive-images-with-images-on-amazon-s3\/\">two settings in the plugin<\/a>:<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Enable Amazon S3 mode<\/strong><\/h3>\n\n\n\n<p>Go to <strong>Settings \u2192 ShortPixel AI \u2192 Behaviour<\/strong> and check the <strong>Amazon S3<\/strong> option. This activates S3-specific URL handling.<\/p>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Set the storage URL<\/strong><\/h3>\n\n\n\n<p>In the <strong>Storage URL<\/strong> field, enter the base CDN path ShortPixel provided in the dashboard:<\/p>\n\n\n\n<p><a href=\"https:\/\/cdn.shortpixel.ai\/xcf\" target=\"_blank\" rel=\"noopener\">https:\/\/cdn.shortpixel.ai\/xcf<\/a><\/p>\n\n\n\n<p><strong>Important:<\/strong> Just the base path. No full S3 URL, no optimization parameters. SPAI builds the rest on its own.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>When this setup makes sense (and when it doesn&#8217;t)<\/strong><\/h2>\n\n\n\n<p><strong>Good fit:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>You serve user-uploaded images from S3 \u2014 marketplaces, SaaS apps, media-heavy sites.<\/li>\n\n\n\n<li>Your images don&#8217;t change every few minutes.<\/li>\n\n\n\n<li>You want optimization without building or maintaining a Lambda pipeline.<\/li>\n\n\n\n<li>You&#8217;re on WordPress with S3-hosted media and want it automated via SPAI.<\/li>\n<\/ul>\n\n\n\n<p><strong>Might not be ideal:<\/strong><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>You need complex transformations like watermarking, face detection, or advanced cropping.<\/li>\n\n\n\n<li>Your images change every few seconds (live feeds, real-time dashboards) \u2014 CDN caching won&#8217;t help much.<\/li>\n\n\n\n<li>You only have a handful of static images, manual optimization with ShortPixel&#8217;s<a href=\"https:\/\/shortpixel.com\/online-image-compression\"> online compressor<\/a> might be simpler.<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>Conclusion<\/strong><\/h2>\n\n\n\n<p>Don&#8217;t serve raw images from S3 when a CDN can optimize them on the fly.<\/p>\n\n\n\n<p>ShortPixel CDN sits between your bucket and your visitors. It compresses, resizes, and converts images to modern formats like <a href=\"https:\/\/shortpixel.com/blog\/jpg-to-webp-why-converting-your-images-is-a-smart-move-and-how-to-do-it\/\">WebP<\/a> and AVIF, automatically. Your originals stay safe in S3, your bandwidth costs drop, and your users get faster pages.<\/p>\n\n\n\n<p>The whole thing is URL-based. No SDKs, no build steps, no Lambda functions to babysit. Connect your bucket, swap the URLs, done.<\/p>\n\n\n\n<p>And if you&#8217;re on WordPress, <a href=\"https:\/\/wordpress.org\/plugins\/shortpixel-adaptive-images\/\" target=\"_blank\" rel=\"noopener\">ShortPixel Adaptive Images<\/a> handles even the URL swapping for you.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><strong>FAQs<\/strong><\/h2>\n\n\n<div id=\"rank-math-faq\" class=\"rank-math-block\">\n<div class=\"rank-math-list \">\n<div id=\"faq-question-1774364748622\" class=\"rank-math-list-item\">\n<h3 class=\"rank-math-question \"><strong>Does ShortPixel modify or delete my original images in S3?<\/strong><\/h3>\n<div class=\"rank-math-answer \">\n\n<p>No. ShortPixel only reads from your bucket. The originals are never modified, moved, or deleted. The CDN fetches them, creates an optimized version, caches it, and serves that cached version to visitors.<\/p>\n\n<\/div>\n<\/div>\n<div id=\"faq-question-1774364759656\" class=\"rank-math-list-item\">\n<h3 class=\"rank-math-question \"><strong>Do I need a public S3 bucket for this to work?<\/strong><\/h3>\n<div class=\"rank-math-answer \">\n\n<p>No. You can use a private bucket. The AWS credentials you provide in the ShortPixel dashboard handle authentication server-side. Your bucket&#8217;s hostname is also stripped from the public CDN URL, so bucket details aren&#8217;t exposed to end users.<\/p>\n\n<\/div>\n<\/div>\n<div id=\"faq-question-1774364771652\" class=\"rank-math-list-item\">\n<h3 class=\"rank-math-question \"><strong>What formats does ShortPixel convert to?<\/strong><\/h3>\n<div class=\"rank-math-answer \">\n\n<p>When you use the to_auto parameter, ShortPixel automatically serves AVIF if the browser supports it, WebP as a fallback, or the original format if neither is supported. You don&#8217;t need to create multiple versions of your images.<\/p>\n\n<\/div>\n<\/div>\n<div id=\"faq-question-1774364782779\" class=\"rank-math-list-item\">\n<h3 class=\"rank-math-question \"><strong>How much smaller will my images be?<\/strong><\/h3>\n<div class=\"rank-math-answer \">\n\n<p>It depends on the originals, but compression combined with next-gen format conversion typically reduces image payloads by 40\u201390%. High-resolution, uncompressed source images see the biggest gains.<\/p>\n\n<\/div>\n<\/div>\n<div id=\"faq-question-1774364791403\" class=\"rank-math-list-item\">\n<h3 class=\"rank-math-question \"><strong>Does this work with any CMS or framework, or just WordPress?<\/strong><\/h3>\n<div class=\"rank-math-answer \">\n\n<p>It works with anything. The CDN URL is just a standard image URL, you can use it in HTML, CSS, JavaScript, React, Next.js, API responses, or any platform that loads images via HTTP. The SPAI plugin is an optional convenience for WordPress users, not a requirement.<\/p>\n\n<\/div>\n<\/div>\n<div id=\"faq-question-1774364803619\" class=\"rank-math-list-item\">\n<h3 class=\"rank-math-question \"><strong>Can I use this alongside CloudFront?<\/strong><\/h3>\n<div class=\"rank-math-answer \">\n\n<p>Yes. You can keep CloudFront for other assets and use ShortPixel CDN specifically for image delivery. The two don&#8217;t conflict.<\/p>\n\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n\n\n<div class=\"wp-block-group has-border-color has-palette-color-4-border-color has-palette-color-6-background-color has-background is-vertical is-content-justification-left is-layout-flex wp-container-core-group-is-layout-e21fc307 wp-block-group-is-layout-flex\" style=\"border-width:1px;border-radius:20px;margin-top:var(--wp--preset--spacing--60);margin-bottom:var(--wp--preset--spacing--60);padding-top:var(--wp--preset--spacing--60);padding-right:var(--wp--preset--spacing--60);padding-bottom:var(--wp--preset--spacing--60);padding-left:var(--wp--preset--spacing--60)\">\n<h3 class=\"wp-block-heading\" id=\"cta-heading\" style=\"margin-top:0;margin-right:0;margin-bottom:0;margin-left:0;padding-top:0;padding-right:0;padding-bottom:0;padding-left:0\">Try ShortPixel on WordPress for free!<\/h3>\n\n\n\n<p>Easily optimize your pictures and cut down pixels fast using ShortPixel Adaptive Images.<\/p>\n\n\n\n<div class=\"wp-block-buttons is-layout-flex wp-block-buttons-is-layout-flex\">\n<div class=\"wp-block-button\"><a class=\"wp-block-button__link wp-element-button\" href=\"https:\/\/wordpress.org\/plugins\/shortpixel-adaptive-images\/\" target=\"_blank\" rel=\"noopener\">Get Started<\/a><\/div>\n<\/div>\n<\/div>\n","protected":false},"excerpt":{"rendered":"<p>If you store images in Amazon S3, chances are you&#8217;re paying more for bandwidth than you should. Every time someone requests an image, S3 serves the original, full resolution, uncompressed, in whatever format you uploaded. No resizing for mobile. No conversion to WebP or AVIF. Just the raw file, every single time. Multiply that by [&hellip;]<\/p>\n","protected":false},"author":37,"featured_media":14758,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[11],"tags":[],"class_list":["post-14743","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-image-optimization"],"blocksy_meta":[],"_links":{"self":[{"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/posts\/14743","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/users\/37"}],"replies":[{"embeddable":true,"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/comments?post=14743"}],"version-history":[{"count":7,"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/posts\/14743\/revisions"}],"predecessor-version":[{"id":14757,"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/posts\/14743\/revisions\/14757"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/media\/14758"}],"wp:attachment":[{"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/media?parent=14743"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/categories?post=14743"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/shortpixel.com\/blog\/wp-json\/wp\/v2\/tags?post=14743"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}