dl
Make your images downloadable with a simple URL parameter
How it works
Section titled “How it works”The dl parameter allows you to control whether an image is displayed in the browser or downloaded automatically. When enabled, the browser will prompt the user to download the image instead of displaying it.
Add ?dl=1 to any HCTI.io image URL to make it downloadable:
https://hcti.io/v1/image/7cb776c5-8c12-4b1a-84aa-9941b815d873.jpg?dl=1Example usage
Section titled “Example usage”HTML download link
Section titled “HTML download link”Create a download button or link:
<a href="https://hcti.io/v1/image/7cb776c5-8c12-4b1a-84aa-9941b815d873.jpg?dl=1" class="download-button"> Download Image</a>JavaScript download trigger
Section titled “JavaScript download trigger”Programmatically trigger a download:
function downloadImage(imageId) { const downloadUrl = `https://hcti.io/v1/image/${imageId}?dl=1`; window.location.href = downloadUrl;}Common use cases
Section titled “Common use cases”- Creating downloadable certificates or badges
- Offering high-resolution versions of images
- Generating downloadable reports or charts
- Providing image assets for users
Need help?
Talk to a human. Email support@htmlcsstoimage.com and we’ll help you get started.