Image format converter JPG PNG WEBP avatar

Image format converter JPG PNG WEBP

Pricing

from $0.00005 / actor start

Go to Apify Store
Image format converter JPG PNG WEBP

Image format converter JPG PNG WEBP

Effortlessly convert and optimize images between formats like JPEG, PNG, WebP, AVIF, and more. Maintain high quality while reducing file size for faster websites, stunning social media visuals, and print-ready graphics.

Pricing

from $0.00005 / actor start

Rating

0.0

(0)

Developer

Akash Kumar Naik

Akash Kumar Naik

Maintained by Community

Actor stats

2

Bookmarked

45

Total users

8

Monthly active users

10 days ago

Last modified

Share

What is Image Format Converter?

Image Format Converter is an Apify Actor that converts images between formats (JPEG, PNG, WebP, AVIF, GIF, TIFF, BMP, HEIF) with quality control and compression optimization. It processes images from any public URL, making it ideal for web developers, photographers, digital asset managers, and e-commerce platforms requiring automated image processing pipelines.

Use cases include:

  • Web optimization – Convert images to WebP or AVIF for faster page loads and reduced bandwidth
  • E-commerce – Standardize product images to consistent formats across catalogs
  • Digital asset management – Batch convert and optimize large image libraries
  • Content marketing – Prepare images for blogs, social media, and publishing platforms
  • Photography workflows – Convert RAW and high-quality formats for web delivery

Features

FeatureDescription
9 Output FormatsJPEG, PNG, WebP, AVIF, GIF, TIFF, BMP, HEIF, and more
Quality ControlAdjustable quality (1-100) for lossy and lossless formats
Compression OptimizationAutomatic ratio reporting and size optimization
Google Drive SupportConvert images from Google Drive files, Docs, Sheets, Slides
Format DetectionAutomatic input format detection from MIME type and URL
Retry LogicBuilt-in retry with exponential backoff for failed downloads
Dimension LimitsSupports images up to 10,000 x 10,000 pixels
Size LimitsHandles files up to 50MB

Supported Formats

FormatBest Use CaseLossy/LosslessCompression
WebPWeb images, modern browsersBothExcellent
AVIFNext-generation web, best compressionBothSuperior
JPEGPhotographs, universal compatibilityLossyGood
PNGTransparency, logos, graphicsLosslessMedium
GIFAnimated imagesLosslessLow
TIFFArchival, print qualityBothVariable
BMPUncompressed bitmapLosslessNone
HEIFApple ecosystem, high efficiencyBothExcellent

Quick Start

1. Provide Image URL

Enter the direct URL of any publicly accessible image.

2. Select Output Format

Choose your target format. WebP is recommended for web optimization.

3. Set Quality (Optional)

Adjust quality from 1-100. Default is 85, optimal for web delivery.


Input Parameters

ParameterTypeRequiredDefaultDescription
imageUrlstringYesPublic URL of image to convert (max 50MB, max 10,000×10,000px)
outputFormatstringYeswebpTarget format: jpeg, png, webp, gif, avif, tiff, bmp, heif
qualityintegerNo85Quality 1-100 (applies to lossy formats)

Example Input

{
"imageUrl": "https://upload.wikimedia.org/wikipedia/commons/thumb/4/47/PNG_transparency_demonstration_1.png/640px-PNG_transparency_demonstration_1.png",
"outputFormat": "webp",
"quality": 85
}

Output Data

Each conversion produces a result object with the following fields:

FieldTypeDescription
originalUrlstringSource image URL
outputUrlstringConverted image URL in Key-Value Store
originalFilenamestringOriginal file name
outputFilenamestringConverted file name
originalFormatstringDetected input format (e.g., "JPEG")
targetFormatstringOutput format (e.g., "WEBP")
originalSizeintegerOriginal file size in bytes
convertedSizeintegerConverted file size in bytes
compressionRatiostringPercentage size change (e.g., "25.00%")
compressionSavingsstringHuman-readable savings (e.g., "0.59MB saved")
statusstringsuccess or error
processingTimeintegerProcessing time in milliseconds
errorstringError message if conversion failed

Example Output (Success)

{
"originalUrl": "https://example.com/photo.jpg",
"originalFilename": "photo.jpg",
"originalFormat": "JPEG",
"targetFormat": "WEBP",
"originalSize": 2457600,
"convertedSize": 1843200,
"compressionRatio": "25.00%",
"compressionSavings": "0.59MB saved",
"outputUrl": "https://api.apify.com/v2/key-value-stores/abc123/records/photo.webp",
"outputFilename": "photo.webp",
"status": "success",
"processingTime": 1250
}

Example Output (Error)

{
"originalUrl": "https://example.com/broken-image.jpg",
"status": "error",
"error": "Failed to download image after 4 attempts: 404 Not Found",
"processingTime": 0
}

Pricing

Pay-per-event (PPE) pricing model – you only pay for successful conversions.

Event Types

EventPriceDescription
image-converted$0.01Successfully converted image
image-download-failed$0.001Failed download attempt

Cost Examples

Images ProcessedCost
1 image$0.01
100 images$1.00
1,000 images$10.00
10,000 images$100.00

Spending Controls

Set a maximum spending limit per run in Apify Console. The Actor automatically stops when the limit is reached.


Integration

REST API

curl -X POST "https://api.apify.com/v2/acts/apify~image-format-converter/run" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"imageUrl": "https://example.com/image.png",
"outputFormat": "webp",
"quality": 90
}'

JavaScript SDK

const { ApifyClient } = require('apify-client');
const client = new ApifyClient({ token: 'YOUR_API_TOKEN' });
const run = await client.actor('apify~image-format-converter').call({
imageUrl: 'https://example.com/image.png',
outputFormat: 'webp',
quality: 90,
});
const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items);

Python SDK

from apify_client import ApifyClient
client = ApifyClient('YOUR_API_TOKEN')
run = client.actor('apify~image-format-converter').call(
run_input={
'imageUrl': 'https://example.com/image.png',
'outputFormat': 'webp',
'quality': 90
}
)
items = client.dataset(run['defaultDatasetId']).list_items()
print(items)

Technical Specifications

SpecificationValue
Maximum file size50 MB
Maximum dimensions10,000 × 10,000 pixels
Memory allocation128 MB – 256 MB
Timeout300 seconds
Retry attempts3 (exponential backoff)

Limitations

  • Output to BMP format converts to PNG due to Sharp library constraints
  • Google Drive integration exports Docs/Sheets/Slides as PDF

Frequently Asked Questions

Q: Which format should I use for web images? A: WebP offers the best balance of compression and compatibility. AVIF provides superior compression but has limited browser support.

Q: What quality setting should I use? A: 80-90 is optimal for web images, balancing quality and file size. Use 95-100 for high-quality archival purposes.

Q: Does the Actor charge for failed conversions? A: Yes, a reduced fee ($0.001) applies for download failures to cover processing costs.

Q: Can I convert multiple images in one run? A: This Actor processes one image per run. For batch processing, use the Apify API to trigger multiple runs programmatically.

Q: Does this support Google Drive images? A: Yes, paste a Google Drive share link and the Actor will automatically convert it for download.