Last updated: Apr-23-2025
Every byte in your web page or app matters. And that's especially true for heavy images and videos. In this step, you'll see how just adding a couple of parameters to a URL will automatically select the best file format for your browser/device and minimize file size of each delivered image and video while maintaining visual quality.
This ensures a top-notch visual experience for your customers and top-notch Core Web Vitals scores for you!
~5 minutes
Task 1: Open the image delivery URLLoad the following Delivery URL to a new browser tab, replacing <your_cloud_name>
below with your actual cloud name:
You'll see an 800kb, high-quality, and large resolution (1870x1250px) JPG image that was included as a sample asset when you created your account.
Continue with the same delivery URL and browser tab from the above task.
In the address bar, just after /upload
(and before the next slash), paste: /q_auto/f_auto
, and reload the image.
Even though you're still delivering an 1870x1250px image, if you download or inspect the image, you'll see that the image size is now only about â or less of its original file size.
Click Forward and Back on your browser to compare between the original and this optimized version. Unless you've got superman-quality vision, you probably won't be able to discern any visual quality difference.
There's no need to deliver high-res images to users and then have them resized client-side in your app. That hurts your page load performance and your end user's experience.
Let's add a couple more parameters to generate a resized image on the Cloudinary servers and then the auto-quality and auto-format parameters you used before will be applied to deliver the best quality and format of the resized variant:
/q_auto/f_auto
, enter: /c_scale,w_500
and reload the image.When adding new components to an existing URL, make sure that the resulting URL has a slash between each component. If you accidentally paste something in the wrong place such that there's a missing slash somewhere, you'll get an error when you reload the URL. If that happens, just skim the URL and check for a missing slash.
Open the sample video below in a new browser tab using your cloud name:
Download or inspect to check the resolution, format, and file size of this original video.
Now add the identical scale, auto-quality, and auto-gravity parameters as you previously added to the image and reload the video.
Wait until the video has loaded and played to end to enable the progressive optimization to complete and then check the video format and file size again.
Cloudinary has tons of backend, frontend, and mobile SDK libraries, all of which enable you to generate optimization (and other) delivery URLs using your favorite programming language.
You'll learn how to set up and use your chosen SDK in step 5, but for now, here's a sneak preview of what the code for generating the above URLs would look like using an SDK.
Take a quick look at the code for your favorite language(s):
Â
I know how to load a delivery URL from my product environment in a browser
I saw how my image was optimized by adding 'q_auto/f_auto' to my delivery URL
I used a resize transformation to further optimize my image
I saw the impact of optimizing a video with 'q_auto/f_auto'
Â
Â
âï¸ Feedback sent!
âï¸Â  ErrorUnfortunately there's been an error sending your feedback.
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4