Actions80
- Add Attachment To PDF
- Add Barcode To PDF
- Add Form Fields To PDF
- Add HTML Header Footer
- Add Image Stamp To PDF
- Add Image Watermark To Image
- Add Margin To PDF
- Add Page Number To PDF
- Add Text Stamp To PDF
- Add Text Watermark To Image
- AI-Invoice Parser
- AI-Process Contract
- AI-Process HealthCard
- Classify Document
- Compress Image
- Compress PDF
- Convert HTML To PDF
- Convert Image Format
- Convert JSON To Excel
- Convert Markdown To PDF
- Convert PDF To Editable PDF Using OCR
- Convert PDF To Excel
- Convert PDF To PowerPoint
- Convert PDF To Word
- Convert To PDF
- Convert URL to PDF
- Convert VISIO
- Convert Word to PDF Form
- Create Images From PDF
- Create PDF/A
- Create Swiss QR Bill
- Crop Image
- Delete Blank Pages From PDF
- Delete Unwanted Pages From PDF
- Split PDF By Barcode
- Disable Tracking Changes In Word
- Enable Tracking Changes In Word
- Extract Attachment From PDF
- Extract Form Data From PDF
- Extract Pages From PDF
- Extract Resources
- Extract Table From PDF
- Extract Text By Expression
- Extract Text From Word
- Fill PDF Form
- Find And Replace Text
- Flip Image
- Flatten PDF
- Generate Barcode
- Generate Document Single
- Generate Documents Multiple
- Get Document From Pdf4me
- Get Image Metadata
- Get PDF Metadata
- Split PDF By Swiss QR
- Get Tracking Changes In Word
- Image Extract Text
- Linearize PDF
- Merge Multiple PDFs
- Overlay PDFs
- Parse Document
- Protect PDF
- Read Barcode From Image
- Read Barcode From PDF
- Read SwissQR Code
- Remove EXIF Tags From Image
- Repair PDF Document
- Replace Text With Image
- Replace Text With Image In Word
- Resize Image
- Rotate Document
- Rotate Image
- Rotate Image By EXIF Data
- Rotate PDF Page
- Sign PDF
- Split PDF By Text
- Split PDF Regular
- Unlock PDF
- Update Hyperlinks Annotation
- Upload File To PDF4me
Overview
The node provides an image resizing operation that allows users to resize images in various input formats. It supports resizing by a percentage scale or by specifying exact dimensions (width and height). The node can maintain the aspect ratio of the image during resizing if desired. This functionality is useful for workflows that require image optimization, thumbnail generation, or preparing images for web or print with specific size requirements.
Common scenarios include:
- Automatically resizing user-uploaded images before storage or display.
- Creating thumbnails from larger images.
- Adjusting image sizes for email attachments or social media posts.
- Batch processing images in automation workflows.
Properties
| Name | Meaning |
|---|---|
| Input Data Type | Choose how to provide the image file to resize: "Binary Data" (from previous node), "Base64 String", or "URL". |
| Input Binary Field | Name of the binary property containing the image file (used if Input Data Type is "Binary Data"). |
| Base64 Image Content | Base64 encoded string of the image content (used if Input Data Type is "Base64 String"). |
| Image URL | URL pointing to the image file to resize (used if Input Data Type is "URL"). |
| Output File Name | Desired name for the output resized image file. |
| Resize Type | Method of resizing: "Percentage" to scale by percent, or "Specific" to set exact width and height. |
| Resize Percentage | Percentage value to resize the image by (used if Resize Type is "Percentage"). |
| Width | Target width in pixels (used if Resize Type is "Specific"). |
| Height | Target height in pixels (used if Resize Type is "Specific"). |
| Maintain Aspect Ratio | Boolean flag to keep the original aspect ratio when resizing. |
| Async | Enable asynchronous processing of the resizing operation. |
| Binary Data Output Name | Custom name for the binary data field in the node's output. |
Output
The node outputs the resized image as binary data under the specified binary data output name (default is "data"). The output includes:
- A JSON object representing the processed item.
- A binary property containing the resized image file data.
- The output file name as specified in the properties.
This allows subsequent nodes in the workflow to access the resized image either for further processing or for saving/exporting.
Dependencies
- The node requires access to image data either via binary input, base64 string, or URL.
- No explicit external API keys or services are indicated in the source code; the resizing logic is handled internally or via bundled dependencies.
- Proper configuration of input data sources (e.g., previous nodes providing binary data or valid URLs) is necessary.
Troubleshooting
- Invalid Input Data: If the input image data is missing or malformed (e.g., invalid base64 string or inaccessible URL), the node may fail. Ensure the input data matches the selected input type.
- Unsupported Image Formats: The node might not support all image formats. Use common formats like JPEG, PNG, or GIF.
- Aspect Ratio Issues: When "Maintain Aspect Ratio" is enabled but specific width and height are provided, the actual output size may differ from the requested dimensions.
- Async Processing: If asynchronous processing is enabled, ensure downstream nodes handle asynchronous outputs correctly.
- File Naming Conflicts: Duplicate output file names in batch operations could cause confusion; use unique names if needed.
Error messages typically relate to invalid inputs or processing failures. To resolve, verify input correctness, network accessibility for URLs, and proper configuration of properties.
Links and References
- Image Resizing Concepts
- Base64 Encoding
- Common Image Formats
- n8n Documentation on Working with Binary Data