Images: Resize an Image

Use this action to adjust the pixel width or height of JPG, JPEG, PNG or WEBP image file. This action accepts images up to 15,000 Pixels and 15MB.

Use case

Resize any image uploaded to Catalytic before using it in other tasks.

If an application or system requires strict file dimension requirements, you can set both width and height of an image manually. If it鈥檚 important to keep the original image鈥檚 proportion, like when uploading a receipt or construction photo, you can scale the image based on a new height or width.

How to configure this action

To resize an image, set the pixel Width and Height you want to resize an image to. In the example below, the original file on the left is 350x450 pixels and the examples on the right show it scaled two different ways, proportionally and non-proportionally

screen readers look here
  • To scale the image proportionally, set just the width or height. In the top example, the height is set to 200 and the width is left empty. When the action is run, the height becomes 200 and the width of the image is automatically scaled to 156 to maintain the original image鈥檚 proportions.
  • To scale the image non-proportionally, set both the width and the height. In the bottom example, the height is set to 200 and the width 300. Since the dimensions are not the same proportion of the original image, the output is stretched.

馃挕Tip: This action accepts images up to 15,000 Pixels and 15MB.

Get the current dimensions of an image without changing the size

Normally, this action outputs the updated width and height of a resized image, based on the new width and height provided. To get the current dimensions of an image without resizing it, leave the width and height fields blank鈥攖hen the output fields will return the actual size of the image.

This is useful to set up conditions based on image size, or as part of quality analysis to verify incoming files meet a standard width and height.

Fields for this action

  • Image file

    • The image to be resized. This will most likely be a reference field to an image uploaded in another field.
  • Width

    • Enter the new image width in pixels. To scale height proportionally with the new width, leave Height blank.
  • Height

    • Enter the new image height in pixels. To scale width proportionally with the new height, leave Width blank.
  • Output Field Prefix

    • This will become the output field name for the new file, and to help keep output fields organized, this will be added to the beginning of each output field name as a prefix as this action may output more than one field.

What will this output?

This action may generate multiple fields. To help keep output fields organized, the prefix above will be added to the beginning of each of the output field names, separated by two dashes. Each field will result as:{{output-field-prefix--output-field}}.

Output fields for this action

  • Image

    • The original, unedited image file.
  • Output Field Prefix

    • The resized image file.
  • File size in bytes

    • The new file鈥檚 size in bytes. This will be an integer.
  • File extension

    • The file extension of the file, such as png or jpg.
  • File type

    • The type of the file in IANA type/subtype format, for example, text/csv or image/png.
  • New Height

    • The new height that was set during configuration, or set automatically if scaled proportionally.
  • New width

    • The new width that was set during configuration, or set automatically if scaled proportionally.

Get help with a problem or question

If something鈥檚 not working as expected, or you鈥檙e looking for suggestions, check through the options below.

Can I use this action to determine an image鈥檚 size?

To get the current dimensions of an image without resizing it, leave the width and height fields blank鈥攖hen the output fields will return the actual size of the image.

This is useful to set up conditions based on image size, or as part of quality analysis to verify incoming files meet a standard width and height.