How to Convert an Image to PNG Format in Power Automate

Cloudmersive
3 min readOct 4, 2024

--

PNG is one of the most popular image formats in the world today — and for good reason. It’s small & efficient, supports transparency, and uses lossless compression algorithms to avoid compromising image quality.

In Power Automate, we can make conversions from dozens of common image formats to PNG using a Cloudmersive Image Processing connector action. Converting to PNG in the context of a Power Automate flow allows us to easily store and/or share our new images through any of our connected applications.

We’ll now walk through a quick example flow that converts an image from JPG format to PNG. We’ll use an instant cloud flow in this context so we can have full control over our data when we test the PNG conversion action.

Set up a manually triggered, instant cloud flow

We’ll begin by adding a Get file content action and retrieving an example image from our file system.

Use a Get file content action to retrieve file bytes

In our next step, we’ll add a new action and type “Cloudmersive” into the search bar. This brings up a list of Cloudmersive connectors. We’re looking for the Cloudmersive Image Processing connector on this list.

Locate the Cloudmersive Image Processing connector

After we click “See more” to view the actions list, we’ll search for an action titled Convert input image to PNG format.

Locate the Convert input image to PNG format action

Once we select this action, we’ll need to authorize our Cloudmersive connection. To do that, we’ll need an API key, which we can get for free by creating a free account on the Cloudmersive website. Our free API key will give us a limit of 800 API calls per month with zero additional commitments.

Next, we’ll incorporate our image file bytes and file name in this action’s two request parameters.

Configure request parameters for the conversion

Finally, we’ll add a Create file action to our flow and save our new PNG file somewhere in our file system. We’ll need to add the “.png” extension to our file name to generate a valid PNG file.

Write the PNG response content to a new file using a Create file action

After we save and test our flow, we’ll find our new PNG in the folder we specified.

Save and test the flow
Verify the new PNG exists in the specified folder

Now we have a version of our image that supports transparency and doesn’t lose any image quality in compression.

--

--

Cloudmersive
Cloudmersive

Written by Cloudmersive

There’s an API for that. Cloudmersive is a leader in Highly Scalable Cloud APIs.

No responses yet