Getting started
Rules Engine Widgets
Image -> Base64
8 min
image → base64 category utility nodes → data conversion what this node does the image → base64 node takes an image (for example, from a url) and converts it into a base64 string you use this when an api or another service needs the image as base64 instead of a normal url or file main settings 1\ input type field input type choose how you will provide the image in the screenshot it is set to image url you give the node a url to an image, and it will download and convert it (if other input types are available in your workspace, pick the one that matches your source, but the idea is the same ) 2\ image input field image input put the image source here, for example an expression like {{dataflow\ current()}} or a url from a previous node the node reads this image before encoding it 3\ output format field output format defines how the encoded data is returned in the screenshot it is set to data uri this gives you a string like data\ image/png;base64, that you can embed directly into html or json (some workspaces may let you choose plain base64 or other formats ) 4\ quality field quality (slider, e g , 80%) controls compression quality when the image is encoded higher quality = better image, larger string lower quality = smaller size, more compression 5\ max width / max height fields max width, max height optional resizing before encoding the image will be scaled down so it does not exceed these dimensions (for example, 1920×1080) useful to avoid huge base64 strings and to standardize image size 6\ include format detection checkbox include format detection (checked in the screenshot) when enabled, the node detects the image format automatically and encodes accordingly this helps handle different input types (png, jpg, etc ) without manual configuration 7\ output the node outputs a base64 string (often as a data uri, depending on output format) you can pass this string to http / api request nodes, ai/vision apis that accept base64, any field that expects image data in base64 form how to use it (step‑by‑step) drag image → base64 into your scenario from utility → data conversion set input type to image url (or another type if needed) in image input , map the image source from a previous node (e g , an uploaded file url) choose output format (e g , data uri) adjust quality and max width/max height if you want to compress or resize the image keep include format detection enabled unless you have a special reason to disable it run the scenario and use the node’s base64 output in your api calls or other nodes best practices use max width/height to keep the output string smaller and faster to send only convert to base64 when required; base64 is bigger than the original binary file if a url fails, check that it is public or accessible from simplita and that it really points to an image this describes the current image → base64 node behavior as shown in the simplita ai ui