Welcome to img-src
img-src is a serverless image processing and delivery API that transforms and delivers your images at the edge. Built on a global edge network, it provides fast, reliable image optimization with minimal latency worldwide.Why img-src?
Edge Processing
Images are processed at 300+ edge locations closest to your users, minimizing latency to under 50ms globally.
On-Demand Transformation
Resize, crop, and convert images via URL parameters. No pre-processing or build steps required.
Modern Formats
Automatic WebP and AVIF delivery based on browser support, reducing bandwidth by up to 50%.
Simple Integration
Drop-in replacement for your image URLs. Works with React, Next.js, Vue, or any static site.
How It Works
- Upload your images via API or dashboard
- Request images with transformation parameters
- Deliver optimized images from the edge cache
Architecture
img-src uses a multi-layer architecture for optimal performance:- CDN Layer: Global edge network caches transformed images
- Edge Computing: Serverless workers handle transformation logic at the edge
- Storage Layer: S3-compatible object storage for originals
- Processing Layer: Native image codecs for high-quality transformations
Quick Example
Upload an image and serve it with transformations:URL Structure
img-src provides two CDN domains:| Domain | Format | Example |
|---|---|---|
| Primary | img-src.io/i/{username}/{path} | https://img-src.io/i/john/photos/hero.jpg |
| Secondary | cdn.img-src.io/{username}/{path} | https://cdn.img-src.io/john/photos/hero.jpg |
Features
Image Transformation
| Parameter | Description | Example |
|---|---|---|
w | Width in pixels | ?w=800 |
h | Height in pixels | ?h=600 |
fit | Fit mode (cover, contain, fill, scale-down) | ?fit=cover |
q | Quality (1-100) | ?q=85 |
p:name | Apply preset (Pro) | ?p:thumbnail |
Supported Input Formats
Common
JPEG, PNG, WebP, GIF
Professional
TIFF, BMP, ICO, SVG
Modern
HEIC/HEIF, AVIF, HDR, EXR
Output Formats
Output format is determined by the file extension in the CDN URL. You can also serve the original format without conversion.| Format | Extension | Best For |
|---|---|---|
| Original | (same as uploaded) | No conversion, fastest delivery |
| WebP | .webp | General use, best compression |
| AVIF | .avif | Maximum compression (max 8MP) |
| JPEG | .jpg, .jpeg | Universal compatibility |
| PNG | .png | Transparency, lossless |
Pro Features
Presets
Save transformation configurations and apply with
?p:nameSigned URLs
Time-limited URLs for private image access
Use Cases
E-commerce Product Images
E-commerce Product Images
Serve product images in multiple sizes for thumbnails, galleries, and zoom views without storing multiple versions.
Responsive Web Images
Responsive Web Images
Generate srcset variations on-the-fly for optimal loading across devices.
User-Generated Content
User-Generated Content
Process uploaded images automatically with consistent sizing and format optimization.
Social Media / OG Images
Social Media / OG Images
Avatar & Profile Images
Avatar & Profile Images
Consistent circular or square avatars across your application.
SDKs & Integrations
Official SDKs are available for popular languages:TypeScript
npm install @img-src/sdk
Python
pip install img-src
Go
go get github.com/img-src-io/sdk-go
Rust
cargo add imgsrc
Rate Limits
API requests are rate limited based on your plan:| Limit Type | Free | Pro |
|---|---|---|
| API Requests | 100/min | 500/min |
| Transformations | 1,000/month | 50,000/month |