Cloudinary offers several methods for naming uploaded resources. Each method has different implications for organization, URL structure, and asset management.
API Upload Naming Option
1. Random Identifier (Default)
- Fully random 20-character public ID
- No parameters needed (default behavior)
- Example:
x2n7kaqbteziwehaivlw
2. Original Filename with Unique Suffix
- Parameters:
use_filename: true
&unique_filename: true
- Example:
my_image_a1b2c3
3. Original Filename As-Is
- Parameters:
use_filename: true
&unique_filename: false
- Will override existing resources with same name
- Example:
my_image
4. Custom Public ID
- Parameter:
public_id: "my_custom_name"
- Will override existing resources with same ID
- Example:
my_custom_name
Media Library (UI) Naming Options
1. Original Filename with Unique Suffix (Default)
- Default for UI uploads
- Example:
my_image_a1b2c3
2. Original Filename As-Is
- Configure in Upload Presets: "Use filename" = True, "Unique filename" = False
- Will override existing resources
- Example:
my_image
3. Custom Public ID
- In the Media Library upload widget, set "Public ID" under "Advanced options"
- Example:
my_custom_name
Choosing the Right Method
- Random IDs: Best for privacy-sensitive assets
- Original Filename + Suffix: Good balance of recognition and uniqueness
- Original Filename: When exact filename preservation is needed
- Custom ID: For SEO-optimized assets or specific naming conventions
Comments
2 comments
It would be great if we can add image size suffix to the end of filename.
For example, I upload image.jpg -> get back image_200x300.jpg
Hi Huy,
You're welcome to submit your request at https://cloudinary.com/roadmap by clicking the "+" at the left bottom corner.
Thanks,
Mo
Please sign in to leave a comment.