Convert Image Format using n8n action
PDF4me Convert Image Format transforms images between different file formats through n8n automation workflows. Process images via n8n triggers, binary data, base64 strings, or public URLs to convert between JPG, PNG, GIF, BMP, WEBP, and TIFF formats with preserved image quality, intelligent color space handling, transparency support, and format-specific optimizations. This solution is ideal for web optimization, format standardization, compatibility requirements, social media preparation, print workflows, and automated format conversion that require reliable image transformation with quality preservation and seamless integration.
Setup
Add the PDF4me "Convert Image Format" node to your n8n workflow and configure the required parameters. For initial setup instructions, see our n8n Integration Guide.
Prerequisites:
- PDF4me API credentials
- n8n workflow access
Configuration:
- Add PDF4me node to workflow
- Select "Convert Image Format" action
- Configure input parameters (see below)

Parameters
Complete list of parameters for the Convert Image Format action. Configure these parameters to control image format conversion.
Important: Parameters marked with an asterisk (***) are required and must be provided for the action to function correctly.
| Parameter | Type | Description | Example |
|---|---|---|---|
| Input Image Data Type | String | Yes | PDF4me image input format selection Choose the format of your source image data input. PDF4me supports multiple input types with different field requirements |
| 1) Binary Data | Yes (One Required) | 1) Binary Data - Use "Input Binary Field" to reference image file from previous node | |
| 2) Base64 String | Yes (One Required) | 2) Base64 String - Use "Base64 Image Content" field for encoded image data | |
| 3) URL | Yes (One Required) | 3) URL - Use "Image URL" field to provide a public/open permission URL to the image file to convert | |
| Input Binary Field | Binary | Yes (If Binary Data) | PDF4me binary image file input - Reference source image file (.jpg, .png, .gif, .bmp) from previous n8n node or file upload. PDF4me processes binary image files with automatic format detection and validation. Required when Input Image Data Type is "Binary Data" |
| Base64 Image Content | String | Yes (If Base64 String) | PDF4me base64 encoded image input - Provide source image data (.jpg, .png, .gif, .bmp) as base64 encoded string for secure transmission. PDF4me automatically decodes and processes the image content. Required when Input Image Data Type is "Base64 String" |
| Image URL | String | Yes (If URL) | PDF4me public image URL input - Provide a public/open permission URL to the source image file (.jpg, .png, .gif, .bmp) to be converted. PDF4me downloads and processes the file from the provided URL. Required when Input Image Data Type is "URL" |
| Current Image Format | String | Yes | PDF4me source format specification - Specify the current format of the input image. PDF4me uses this information to optimize the conversion process and ensure accurate format handling |
| JPG | Yes (One Required) | JPEG Format - Joint Photographic Experts Group format with lossy compression, commonly used for photographs and complex images | |
| PNG | Yes (One Required) | PNG Format - Portable Network Graphics format with lossless compression and transparency support | |
| GIF | Yes (One Required) | GIF Format - Graphics Interchange Format with limited colors and animation support | |
| BMP | Yes (One Required) | BMP Format - Bitmap format with uncompressed pixel data | |
| WEBP | Yes (One Required) | WEBP Format - Modern web image format with superior compression and quality | |
| TIFF | Yes (One Required) | TIFF Format - Tagged Image File Format with lossless compression and professional features | |
| New Image Format | String | Yes | PDF4me target format selection - Choose the desired output format for the converted image. PDF4me supports multiple formats with different characteristics and optimization features |
| JPG | Yes (One Required) | JPEG Format - Joint Photographic Experts Group format with lossy compression, ideal for photographs and complex images with excellent file size reduction | |
| PNG | Yes (One Required) | PNG Format - Portable Network Graphics format with lossless compression, ideal for graphics with transparency and sharp edges | |
| GIF | Yes (One Required) | GIF Format - Graphics Interchange Format with limited colors, ideal for simple graphics and animations | |
| BMP | Yes (One Required) | BMP Format - Bitmap format with uncompressed data, ideal for high-quality archival purposes | |
| WEBP | Yes (One Required) | WEBP Format - Modern web image format with superior compression and quality, ideal for web optimization | |
| TIFF | Yes (One Required) | TIFF Format - Tagged Image File Format with lossless compression, ideal for professional printing and archival | |
| Output File Name | String | Yes | PDF4me converted image output filename - Specify the name for the generated converted image file with proper extension (.jpg, .png, .gif, .bmp, .webp, .tiff). PDF4me ensures unique naming and validates file format compliance |
| Binary Data Output Name | String | Yes | PDF4me binary data mapping - Define the variable name for accessing the generated converted image binary data in your n8n workflow. This binary data can be used as input data in subsequent actions within your workflow |
Supported Image Formats
| Format | Description | File Extensions | Max Size | Compression Type | Best Use Cases |
|---|---|---|---|---|---|
| JPEG | Joint Photographic Experts Group with lossy compression optimized for photographs | .jpg, .jpeg | 50MB | Lossy | Photographs, complex images, web content, social media |
| PNG | Portable Network Graphics with lossless compression and transparency support | .png | 50MB | Lossless | Graphics with transparency, logos, screenshots, web graphics |
| GIF | Graphics Interchange Format with limited color palette and animation support | .gif | 50MB | Lossless | Simple graphics, animations, web icons, low-color images |
| BMP | Bitmap image format with uncompressed pixel data | .bmp | 50MB | Uncompressed | High-quality archival, professional printing, detailed graphics |
| WEBP | Modern web image format with superior compression and quality | .webp | 50MB | Lossy/Lossless | Web optimization, modern browsers, mobile applications |
| TIFF | Tagged Image File Format with lossless compression and professional features | .tiff, .tif | 50MB | Lossless | Professional printing, archival, high-quality documents |
Output
Output Parameters
| Parameter | Type | Description | Example |
|---|---|---|---|
| fileName | String | PDF4me generated image filename - The complete filename of the successfully converted image with proper extension. PDF4me ensures unique naming and validates file format compliance for seamless integration with downstream processes | converted_image.png |
| fileSize | Number | PDF4me converted image file size in bytes - The exact size of the generated converted image file in bytes, provided by PDF4me for storage planning, bandwidth optimization, and file transfer monitoring. Essential for enterprise image management and workflow automation | 125430 |
| originalFileSize | Number | PDF4me original file size in bytes - The size of the original image file before conversion, provided for comparison and conversion efficiency calculation | 245760 |
| originalFormat | String | PDF4me source format confirmation - The original format of the input image, confirming the source format that was processed during conversion | JPG |
| convertedFormat | String | PDF4me target format confirmation - The final format of the converted image, confirming the target format that was generated during conversion | PNG |
| success | Boolean | PDF4me conversion status indicator - Boolean flag indicating the success or failure of the image format conversion process. PDF4me returns true for successful operations and false for any errors, enabling robust error handling in automated workflows | true |
| mimeType | String | PDF4me output MIME type - MIME type of the generated converted image file (e.g., "image/jpeg", "image/png"). Useful for content type validation and proper file handling in web applications | image/png |
| message | String | PDF4me conversion status message - Human-readable status message providing details about the image format conversion process result. Includes success confirmation or error details for troubleshooting | Image format converted successfully |
N8N Action Response
The PDF4me Convert Image Format API returns a response that can be viewed in multiple formats. Choose the view that best fits your needs:
- JSON
- Table
- Schema
- Binary
JSON Response Format
The raw JSON response from the API:
[
{
"success": true,
"message": "Image format converted successfully",
"fileName": "converted_image.webp",
"mimeType": "image/png",
"fileSize": 125430,
"originalFileSize": 245760,
"originalFormat": "JPG",
"convertedFormat": "PNG"
}
]
Table View
Response data in a structured table format:
| Parameter | Value |
|---|---|
| success | true |
| message | Image format converted successfully |
| fileName | converted_image.png |
| mimeType | image/png |
| fileSize | 125430 |
| originalFileSize | 245760 |
| originalFormat | JPG |
| convertedFormat | PNG |
Schema View
The data structure and types of the response:
1 item
success: ☑ true
message: AB Image format converted successfully
fileName: AB converted_image.png
mimeType: AB image/png
fileSize: # 125430
originalFileSize: # 245760
originalFormat: AB JPG
convertedFormat: AB PNG
Type Indicators:
AB= String#= Number☑= Boolean
Binary Data View
The actual converted image file data and metadata:
data
─────────────────────────────
File Name: converted_image.png
File Extension: png
Mime Type: image/png
File Size: 122.5 KB
Binary Data Access:
- n8n Binary Object:
$binary.data.data - Base64 Content: Available for direct use
- File Operations: Ready for download, email, or storage
Use Cases
Web Optimization and Compatibility
- Convert images to web-optimized formats like WEBP for modern browsers
- Transform legacy formats to standard web formats for better compatibility
- Optimize images for different devices and screen resolutions
Content Management and Archival
- Standardize image formats across content management systems
- Convert images to archival formats like TIFF for long-term storage
- Transform images for different publishing platforms and requirements
E-commerce and Marketing
- Convert product images to optimal formats for online stores
- Transform marketing materials for different social media platforms
- Optimize images for email campaigns and digital advertising