Power Automate Create PDF + 11 Examples

In this Microsoft Power Automate Tutorial, we will discuss how to create a pdf using Power Automate. Also, we will see the below topics:

  • Power Automate create pdf free
  • Power Automate create pdf from html
  • Power Automate create pdf from SharePoint items
  • Power Automate create pdf from word
  • Power Automate create pdf from form
  • Power Automate create pdf from excel
  • Power Automate create pdf from email
  • Power Automate create pdf from Power BI
  • Power Automate create pdf without premium
  • Power Automate create pdf get file content
  • Power Automate create PDF without OneDrive

Power Automate create pdf

PDF stands for ‘Portable Document Format‘. If we save the file in PDF format it can’t be modified. But it can be easily shared and printed. Now we will see how to format the different kinds of files to PDF format.

Power Automate create PDF free

Power Automate allows us to create PDFs freely. Yes, we can create PDFs without using any premium actions or connectors. Here we will see how to create a PDF free using Power Automate.

Before creating the flow, make sure to log in the Power Automate with your Microsoft user ID. Let’s have a look at the below steps to create a flow.

Step-1: Trigger the flow manually

On Power Automate, let’s create an instant flow that will trigger it manually. For this, go to My flow > +New flow > Instant cloud flow. Give a name to your flow.

Create a button flow on Power Automate
Create a button flow on Power Automate

Then select the trigger to start the flow i.e. Manually trigger a flow.

Trigger the flow manually
Trigger the flow manually

Step-2: Add HTML

Next, we will add a compose action using HTML tags. Click on + New step > Compose. Here we will add the below HTML code as input.

<!DOCTYPE html>
<html>
<body>

<h2>Hi</h2>
<h3>Have a Good Day</h3>

</body>
</html>
Power Automate Create PDF free
Power Automate Create PDF free

Step-3: Create an HTML file

Next, we will create an HTML file within the OneDrive as a temporary location. That will help us to convert the file into PDF format.

Clock on +New step > Create File(under OneDrive). It will ask to set the below properties:

  • Folder Path- Set Root as temporary folder path
  • File Name– Give a name to the file using ‘.html’ extension
  • File Content- Select the output from the Compose action
Create PDF free using flow
Create PDF free using flow

Step-4: Convert the file to PDF

Now, we will add an action that will convert the HTML file to PDF format. For this, click on +New step > Convert file(Preview). Here we will set the ID from the dynamic content of Create file as a file and set the target type as PDF.

Create PDF free in Power Automate
Create PDF free in Power Automate

Step-5: Create the PDF file

In this final step, again we will add an action that will upload the converted PDF file in the OneDrive.

Click on +New step > Create file(under OneDrive). Similarly, set the properties such as:

  • Folder Path– Select a folder path where you want to upload the PDF file.
  • File Name & File Content– Select file name and file content from the dynamic content of the Convert file.
How to create a PDF free using Power Automate
How to create a PDF free using Power Automate

Now, our flow is complete and it’s ready to run. Let’s save this flow and test it manually. Then click on Run flow. we can see the flow ran successfully without fail.

Create a PDF free in Power Automate
Create a PDF free in Power Automate

Also, we can see the PDF file inside the specified OneDrive folder.

Create a PDF free using flow
Create a PDF free using flow

If we click on the PDF it will show the content that we have written in the HTML.

How to create a PDF free using flow
How to create a PDF free using flow

This is how to create a PDF free using Power Automate.

Power Automate create pdf from html

Here, we will see how to create a PDF file from HTML using Power Automate. For this, we will create a flow that will convert the HTML into PDF and send it to the specified user via outlook.

The following steps are:

Step-1:

Let’s create an instant flow that will trigger the flow manually. Go to My flow > +New flow > Instant cloud flow.

Create a button flow on Power Automate
Create a button flow on Power Automate

Then select a trigger from the list that will trigger the flow manually and press Create.

Create an instant flow on Power Automate
Create an instant flow on Power Automate

Now our flow is started.

Step-2:

Next, we will add a compose action where we will use the below static HTML tag as inputs. Go to +New step > Compose > insert the below HTML code inside the inputs.

<html>
<head>
<title> Testing </title>
</head>
<body>
<h2>TSInfo Technologies</h2>
<h3>Delivering Business At The Best</h3>
</body>
</html>
Power Automate create pdf from html
Power Automate create pdf from HTML

Step-3:

Next, we will add an action that will create a file. Click on +New step > create file.

create pdf from html using Power Automate
create pdf from HTML using Power Automate

it will ask to set the following properties like below:

  • Folder Path– Here we will set the path as /PDF. If the path is not available then it will create it automatically.
  • File Name– Give a file name using the extension as .html(ex- sample.html).
  • File Content– Select the output from the Compose action
Create PDF documents from Html in Power Automate
Create PDF documents from Html in Power Automate

Step-4:

Next, we will add an action that will convert the created file into PDF format. Go to +New step > Convert file. Set the parameters such as:

  • File- Select ID from Create file action.
  • Target type- PDF
How to create PDF from HTML Power Automate
How to create PDF from HTML Power Automate

Step-5:

This is the final step where we will send the formatted PDF file to a specified user via outlook.

Go to +New step > Send an email. Set the following properties below:

  • To- Give a user id to whom we want to send the email with PDF.
  • Subject- Give a subject to the email.
  • Body- Set the body of the email.
How to convert HTML to PDF using Power Automate
How to convert HTML to PDF using Power Automate

Now just save the flow and select to test it manually.

How to automatically convert HTML to PDF in Power Automate
How to automatically convert HTML to PDF in Power Automate

Then click on Run flow.

Power Automate convert to PDF
Power Automate convert to PDF

We can see it will send an email to the specified user.

How to convert HTML file to PDF using Power Automate
How to convert HTML file to PDF using Power Automate

We can see the Html that we have created by clicking on the PDF.

How to create a PDF from HTML using Power Automate
How to create a PDF from HTML using Power Automate

This is how to create a PDF from HTML using Power Automate.

Power Automate create pdf from SharePoint list items

Here we will see how to create a PDF from the SharePoint list items using Power Automate.

For this, we have created a SharePoint list based on Vehicle Registration having columns such as:

Column Name Column Type
VehicleNumber A single line of text
OwnerName A single line of text
RegisteringAuthority A single line of text
FuelType Choice
Engine Number A single line of text
registration date A single line of text
Power Automate create pdf from SharePoint list
Power Automate create pdf from SharePoint list

Let’s create a flow that will create PDF from the SharePoint list. The following steps are:

Step-1:

First, we will create an automated flow that will trigger when an item is created in the SharePoint list.

Go to +Create > When an item is created. Then configure the trigger with the SharePoint site address and the list name.

Power Automate create pdf from SharePoint list items
Power Automate create pdf from SharePoint list items

Step-2:

Next, we will add an action that will get all the items from the SharePoint list.

Go to + New step > Get items. Set the properties as follows:

  • Site Address- Set the SharePoint site address
  • List Name- Specify the SharePoint list name
create pdf from SharePoint list Power Automate
create pdf from SharePoint list Power Automate

Step-3:

Next, we will add an action that will create an HTML table using given data.

Go to + New step > Create HTML table. Set the properties like below:

  • From- Value (select from get items)
  • Columns- Custom
Header Value
VehicleNumber vehicle Number
OwnerName Owner Name
RegisteringAuthority Registering Authority
FuelType Fuel Type
Engine Number Engine Number
registration date Registration Date

Note– Select value from the dynamic content.

Generate PDF from SharePoint list item
Generate PDF from SharePoint list item

Step-4:

Next, we will add an action that will create a file on the OneDrive. Go to +New step > Create file. Set the properties like below:

  • Folder Path– Give a folder path.
  • File Name– Give a name with html extension.
  • File Content– Output from the create HTML table.
Convert SharePoint List Items to PDF with Power Automate
Convert SharePoint List Items to PDF with Power Automate

Step-5:

Then, we will add an action that will convert one file to another format. Go to +Create > Convert file.

  • File-Select ID from dynamic content of create file
  • Target type- PDF
Create PDF Documents from SharePoint Data in Power Automate
Create PDF Documents from SharePoint Data in Power Automate

Step-6:

In this final step, again we will add an action that will create a pdf file from the Html file. Go to +New step > Create file. Set the following properties below:

  • Folder Path– Give a fiolder path (ex- /PDF)
  • File Name- Give a file name
  • File Content– Select file content from the dynamic content of onedrive.
Convert SharePoint list items into PDF using Power Automate
Convert SharePoint list items into PDF using Power Automate

Now our complete flow looks below:

Convert a SharePoint List item to PDF Using Microsoft Flow
Convert a SharePoint List item to PDF Using Microsoft Flow

Let’s save the flow. Test it manually. Then insert data in the Vehicle Details list.

SharePoint list item into PDF
SharePoint list item into PDF

We can see the flow ran successfully without any lack.

Convert PDF from SharePoint list items using Power Automate
Convert PDF from SharePoint list items using Power Automate

As the flow ran successfully, we can check the PDF created in the Onedrive:

power automate convert SharePoint list to PDF
power automate convert SharePoint list to PDF

We can see all the items from the SharePoint list got stored in PDF format:

power automate convert SharePoint list items to PDF
power automate convert SharePoint list items to PDF

This is how to convert SharePoint list items to PDF using Power Automate.

Read Power Automate Filter Array

Power Automate create pdf from word

Here we will see how to create a PDF from a word file using Power Automate. To implement this, we are going to create an automated flow that will convert a word file to a PDF and store it in a specified SharePoint document library folder.

Here we have prepared 2 folders in the document library one is the source folder where we upload the word files and another one is the destination folder where the PDFs are stored that converted from the word files.

create pdf from word using Power Automate
create pdf from word using Power Automate

Now we will create the automated flow, and the following steps are:

Step-1:

On Power Automate, Go to +Create > Automate cloud flow > Select the trigger ‘when a file is created(Properties only)‘ > Create. Also, you can give a name to the flow.

Power Automate create pdf from word
Power Automate create pdf from word

Then it will ask to configure the trigger with the SharePoint by specifying the following properties below:

  • Site Address– Specify the SharePoint site address
  • Library Name– Select the SharePoint document library
  • Folder– choose the folder path where we uplaod the word file in the SharePoint document library(Source folder).
Using Flow to convert Word documents to PDFs
Using Flow to convert Word documents to PDFs

Step-2:

Next, we will add an action that will get the file content using the file identifier. To add this action, click on + New step > Get file content(under SharePoint).

Set the SharePoint site address and in the file identifier, select the identifier from the dynamic content.

Convert Word to PDF using Power Automate
Convert Word to PDF using Power Automate

Step-3:

Now, we will add an action to create the files in the Onedrive as temporary storage. For this, click on +New step > Search for Create file(under OneDrive). Set the properties like below:

  • Folder Path– Select Root as folder path.
  • File Name– Select File name with extension from the dynamic content of ‘When a file is created’.
  • File Content– Select File content from the dynamic content of ‘Get file content‘.
Power Automate – Convert Word document to PDF
Power Automate – Convert Word document to PDF

Step-4:

Then we will add another action that will convert the file from one format to another i.e. PDF format. Set the properties like below:

  • File- Select Id from the dynamic content of create file.
  • Target type– Select PDF from the dropdown.
Create PDF Using Word with Microsoft Flow
Create PDF Using Word with Microsoft Flow

Step-5:

Next, we will add an action that will create the converted file in the SharePoint document library i.e. destination folder.

Click on +New step > Create file and set the properties like below:

  • Site Address– Set the Sharepoint site address.
  • Folder Path– Specify the folder path where we want to store the converted pdf files.
  • File Name– Select the File name from the trigger with ‘.pdf’ extension.
  • File Content– Select the File content from the dynamic content of convert file.
Converting Word Doc to PDF using Power Automate
Converting Word Doc to PDF using Power Automate

Step-6:

After creating the file, we will add an action that will delete the file from the temporary storage i.e. One drive location.

Click on +New step > Delete file (under OneDrive). Here we will set the ID as a File.

Flow Action Convert Word Document to PDF
Flow Action – Convert Word Document to PDF

Step-7:

Next, we will add an action that will delete the word file from the source folder of the SharePoint document library. Click on + New step > Delete file. Set the parameters like below:

  • Site Address– Set the SharePoint site address.
  • File Identifier– Select the identifier from the trigger.
Convert DOCX to PDF in Power Automate
Convert DOCX to PDF in Power Automate

Now our flow is complete. The entire flow looks like below:

How to convert Microsoft Word document to PDF using Power Automate
How to convert Microsoft Word document to PDF using Power Automate

Let’s save the flow and test it manually. Then upload a word file in the source folder.

Convert Word to PDF using flow
Convert Word to PDF using flow

We can see it will convert the word file into PDF and store it within the destination folder.

Convert Word to PDF with SharePoint & Power Automate
Convert Word to PDF with SharePoint & Power Automate

Also, we can see the file got deleted from the secondary storage:

How To Convert Word Documents To PDF Using Power Automate
How To Convert Word Documents To PDF Using Power Automate

This is how To Convert Word Documents To PDF Using Power Automate.

Power Automate create pdf from form

Here we will see how to create a PDF from the Microsoft form using Power Automate. Before creating a PDF from the Microsoft form, we will see how to create a Microsoft form, and then we will see how to convert this form to PDF.

Create a Microsoft Form

Let’s create a simple Microsoft form by following these steps:

In the SharePoint environment, click on App Launcher > Select Form.

Create a Microsoft form
Create a Microsoft form

Then click on +New Form where we can easily create a Microsoft form and give a name to the Microsoft form.

Create a Microsoft form
Create a Microsoft form

Click on the +Add new to add the questions according to their type.

How to create a Microsoft form under SharePoint
How to create a Microsoft form under SharePoint

This is how we have created a simple Microsoft form under SharePoint.

Creating a Microsoft form
Creating a Microsoft form

Next, click on Share(on right side) > Copy the link > Open it another tab.

Microsoft form to PDF convert
Microsoft form to PDF convert

Create a flow to convert the Form into PDF

Let’s create an automated flow that will create a pdf when a response is submitted via Microsoft form. Also, we will see how to store this PDF in the SharePoint folder and also, send this PDF to another user or manager.

The following steps are:

Step-1: Trigger the flow when a new response is submitted

Open the Power Automate, Click on + Create > Automate Cloud flow > Select the trigger ‘When a new response is submitted. It will ask to choose the Form Id(i.e. your form name-Employee information).

Microsoft flow create pdf from form
Microsoft flow create pdf from form

Step-2: Get the response details

Next, we will add an action that will retrieve a form response from the Microsoft form. Go to +New step > Get response details. It will ask to set the prop[erties like below:

  • Form Id– Select the form
  • Response Id– Select Response Id from the dynamic content of the trigger.
Create PDF from Microsoft form Power Automate
Create PDF from Microsoft form Power Automate

Step-3: Add select action to create an array

Next, we will add a select action that will select the specified properties from all elements of the ‘from‘ array into a new array.

In From, we will add the below expression that will create a new array:

createArray(triggerOutputs()?['body/resourceData/responseId'])

In Map, Enter the key as the questions(that are asked in the form) and set the values from the dynamic content of Get response details.

Power Automate create pdf from form
Power Automate create a pdf from the form

Step-4: Create HTML table

After creating an array, we will convert the output of these properties into an HTML table. Go to +New step > Create HTML table. Set the output as From.

Power Automate create pdf from Microsoft form
Power Automate create pdf from Microsoft form

Step-5: Add a compose action

Next, we will add a Compose action using an expression that will convert the HTML table with borders.

Click on +New step > Compose > Expression. Insert teh below expression.

replace(body('Create_HTML_table'),'<table>','<table border = "2">')
How to generate a PDF from Microsoft Forms
How to generate a PDF from Microsoft Forms

Step-6: Create the file in the temporary location

Next, we will add an action that will create a file in the temporary location i.e. OneDrieve that will help to convert the file into PDF.

Click on +New step > Create file. Set the parameters like below:

  • Folder Path– Set Root or give a ‘/’ as folder path.
  • File Name- Select ‘Fullname’ with ‘Employee No’ from the dynamic content as file name with ‘.html’ extension.
  • File Content– Set the Output of the Compose from the dynamic content.
Microsoft Forms to PDF using Flow
Microsoft Forms to PDF using Flow

Step-7: Convert the Html file to PDF

Now, we will add an action that will convert the HTML file to PDF. Go to +New step > Convert file(under OneDrive). Set the properties like below:

  • File– Select ID from the dynamic content of Create file.
  • Target type– Set type as PDF.
Convert Microsoft Forms with attachments to PDF
Convert Microsoft Forms with attachments to PDF

Step-8: Add action to create a file

Next, we will add an action that will upload a file to a SharePoint library. Click on +New step > Create file(under SharePoint). Set the properties like below:

  • Site Address– Set the SharePoint site address
  • Folder Path– Set the folder path where you want to upload the file in SharePoint document library.
  • File Name– Choose File name from the dynamic content of Convert file.
  • File Content– Choose File content from the dynamic content of the Convert file.
Convert responses from Microsoft Form to PDF
Convert responses from Microsoft Form to PDF

Step-9: Getting the file content

Next, we will add an action that will get all the file content from the file. Click on +New step > Get file content. It will ask to set the properties like below:

  • Site Address– Set the SharePoint Site address.
  • File Identifier– Set the id from the create file.
Microsoft Forms to PDF No Premium Actions
Microsoft Forms to PDF – No Premium Actions

Step-10: Send an email

In the final step, we will add an action that will send an email with the PDF attachment via outlook. Click on + New step > Send an email(V2). Set the properties like below:

  • To– Set an User ID to whom want to send this email.
  • Subject– Set a subject name to the email.
  • Body– Specify the body of the email. Expand the advance option and set the Attachment’s name as Name from the Create file(SharePoint) and set File content from Get file content as Attachments content.
Flow to create PDF from the Microsoft form
Flow to create PDF from the Microsoft form

Now, we can see what the entire flow looks like below:

How to create PDF from Microsoft form Power Automate
How to create PDF from Microsoft form Power Automate

Let’s save the flow. Test it manually. Then submit a response in the form. It will show a success message after the response is submitted. For example, here we have set the full name as John William and his details.

Power Automate Microsoft form to PDF
Power Automate Microsoft form to PDF

Now, we can see it will convert this form to PDF and upload this file to the specified SharePoint document library folder.

Create PDF from Microsoft Forms
Create PDF from Microsoft Forms

Also, we can check the email with the PDF attachment like below:

How to convert Microsoft form to PDF using Power Automate
How to convert Microsoft form to PDF using Power Automate

This is how to convert Microsoft form to PDF using Power Automate.

Power Automate create pdf from excel

Here we will see how to create a Pdf from an excel file. For example, when the user uploads an excel file on the SharePoint folder it will convert this excel file to PDF, also upload this file into the specified folder.

Let’s create an automated flow on Power Automate and the following steps are here:

Step-1: Trigger the flow when a file is created

On Power Automate, click on +Create > Automated cloud flow > Select the trigger When a file is created. Set the properties like below:

  • Site Address– Specify the SharePoint site address.
  • Library Name– Select the document library name.
  • Folder– Select the folder path where the excel file will upload.
Convert XLSX to PDF in Power Automate
Convert XLSX to PDF in Power Automate

Step-2: Get the file content from the document library

Next, we will add an action that will get the file content using a file identifier from the SharePoint document library. Click on +New step > Get file content. It will ask to set the site address and File identifier(select the identifier from the dynamic content).

Convert Excel Worksheet to PDF in Power Automate
Convert Excel Worksheet to PDF in Power Automate

Step-3: Create a new file on secondary storage

Next, we will add an action that will create a file in the temporary storage. This process will help us to convert the file from one format to another format.

Click on +New step > Create file (under OneDrive for business). It will ask to set the below parameters:

  • Folder Path– Set Root as folder path or you can type ‘/‘.
  • File Name– Select File name with extension from the dynamic content of the trigger.
  • File Content– Select File content from Get file content.
create pdf from excel using flow
create pdf from excel using flow

Step-4: Convert the file to the targeted format

Now, we will add an action that will convert the file from one format to another format i.e. excel file to PDF format.

To add this action, click on +New step > search and select Convert file(preview). Set the File as Id from the create file action and set the target type as PDF.

Converting Excel to PDF Power Automate
Converting Excel to PDF Power Automate

Step-5: Create a PDF file

In this step, we will add an action that will create the converted file i.e. PDF file in the specified SharePoint document library. Click on +New step > Create file(under SharePoint). It will ask to set the following parameters:

  • Site Address– Set the SharePoint site address
  • Folder Path– Specify the SharePoint folder path where the PDF will upload
  • File Name- Select File name from convert file’s dynamic content.
  • File Content– Select File content from the Convert file’s dynamic content.
How to use Power Automate to convert Excel sheet to PDF
How to use Power Automate to convert Excel sheet to PDF

Step-6: add action to delete the file

This is the final step of the flow where we will delete the file from the temporary storage i.e. OneDrive.

Click on +New step > Delete file (under OneDrive for business). Select id from Create file (under OneDrive) as File.

How To Convert Excel Sheets To PDF Using Power Automate
How To Convert Excel Sheets To PDF Using Power Automate

Now our flow is ready. This is what the entire flow looks like:

Convert PDF to Excel with Power Automate
Convert PDF to Excel with Power Automate

Let’s save the flow and test it manually. Next, we will insert an excel file in the specified SharePoint folder. For example, we will insert an excel file named ‘SuperStoreUS-2015’ and we can see it will create a PDF of that excel file.

Power Automate create pdf from excel
Power Automate create pdf from excel

Also, we can see our flow ran successfully as there is no error during the conversion process.

How to Convert an Excel Spreadsheet to PDF in Power
How to Convert an Excel Spreadsheet to PDF in Power

This is how to Convert an Excel Spreadsheet to PDF in Power.

Note- You can delete the excel file from the SharePoint document library also. For this, under the last action(Delete file), click on +New step > Delete file(under SharePoint). Set the SharePoint site address and in the File identifier, set Identifier from the trigger i.e. ‘When a file is created (properties only)‘.

Microsoft flow convert PDF from the excel
Microsoft flow convert PDF from the excel

This is how to do Microsoft flow convert PDF from /excel.

Power Automate create pdf from email

Now we will see how to create a PDF file from email. For example, when a user sends an email it will convert it into PDF and upload it into the specified document library. The following steps are:

Step-1: Trigger the flow when an email is arrives

On Power Automate, click on +Create > Automated cloud flow > select the trigger ‘When a new email arrives (V3)‘. Expand the advanced options. Set a user id as To.

create pdf from email Power Automate
create pdf from email Power Automate

Step-2: Export the email(v2)

Next, we will add action to export the content of the email in the EML file format using Message-Id. Click on +New step > Export email (V2).

Convert email message to PDF in Power Automate
Convert the email message to PDF in Power Automate

Step-3: Create a file

Next, we will add an action that will create a file in a temporary location i.e. OneDrive. Click on + New step > Create File. Set the properties such as:

  • Folder Path– Set Root as folder path.
  • File Name– Select Subject from the dynamic content of the trigger using ‘.eml‘. It will create a message within the OneDrive.
  • File Content– Select body from the dynamic content of the Export email.
How To create PDF Email With Power Automate
How To create PDF Email With Power Automate

Step-4: Convert a file from one format to another

Next, we will add an action to convert the created file from message file to PDF. For this, click on +New step > Convert file(preview). Select Id from creating a file in the File input and set the target type as PDF.

save email as pdf using flow
save email as pdf using flow

Step-5: Upload the converted file in the SharePoint folder

Next, we will add an action that will upload the converted PDF file in the specified SharePoint folder. Click on + New step > Create file. Set the properties like below:

  • Site Address- Specify the SharePoint site address.
  • Folder Path- Choose the folder path where you want to upload the file.
  • File Name- Select the file name from the dynamic content of the convert file.
  • File Content- Select the File convert from the dynamic content of the convert file.
Converting Emails to PDF in Power Automate
Converting Emails to PDF in Power Automate

Step-6: Delete the file from the temporary storage

In this final step, we will add an action that will delete the message from the temporary storage. Click on +New step > Delete file. Set Id as File.

Convert Email to PDF using Microsoft flow or Power Automate
Convert Email to PDF using Microsoft flow or Power Automate

Now, the flow is complete. This is what the entire flow looks like:

Convert your email to PDF using Power Automate
Convert your email to PDF using Power Automate

Let’s save the flow and test it manually. For testing purposes, let’s send an email from another user-id to our email via outlook.

Convert email to PDF using Power Automate
Convert email to PDF using Power Automate

We can our flow run successfully unless the flow will fail and show an error message if is there any error.

How to Convert Email to PDF using MS flow
How to Convert Email to PDF using MS flow

Also, we can see the email convert to PDF and upload this file in the specified folder.

Convert email message to PDF using Power Automate
Convert the email message to PDF using Power Automate

This is how to convert email messages to PDF using Power Automate.

Power Automate create pdf without premium

Here we will see how to create a PDF dynamically without using any premium action. For this, we will create an instant button flow on Power Automate. Where we can instantly create a PDF from the dynamic data. The following steps are:

Step-1: Trigger the flow

On Power Automate, go to +Create > Instant cloud flow > Manually trigger the flow and give a name to the flow.

Power Automate trigger a flow manually
Power Automate trigger a flow manually

Here we will add some inputs such as text(for name), Email(for employee’s email), Number(for contact), Date(for join date).

Generate a PDF in Power Automate without premium
Generate a PDF in Power Automate without the premium

Step-2: Add a compose action

Next, we will add a Compose action where we will create an HTML structure using dynamic contents. Click on +New step > Compose > Expression.

<html>
<head></head>
<body>
<p>Name: @{triggerBody()['text']}</p>
<p>Email:@{triggerBody()['email']}</p>
<p>Contact: @{triggerBody()['number']}</p>
<p>Join Date: @{triggerBody()['date']}</p>
</body>
</html>
Create a PDF without any Premium connectors
Create a PDF without any Premium connectors

Step-3: Create an Html file

Next, we will add an action that will create an HTML file within the secondary storage i.e. OneDrive. Click on +New step > Create file(under OneDrive). Set the parameters such as:

  • Folder Path– Root
  • File Name– Give name with ‘.html’ extension (i.e. @{triggerBody()[‘text’]}.html)
  • File Content– Use Output from the compose action.
Creating PDF without using premium action Power Automate
Creating PDF without using premium action Power Automate

Step-4: Convert the Html file to pdf

Next, we will add an action that will convert the HTML file into PDF format. Click on +New step > Convert file(preview). Then set the file as ID from the dynamic content of Create file and Target type as PDF.

power automate create pdf without premium
power automate create pdf without the premium

Step-5: Upload the PDF to another location

Now, we will add an action that will upload the PDF file in the specified SharePoint folder. Click on + New step > Create file. Set the properties like below:

  • Site Address– Specify the SharePoint site address
  • Folder Path– Select a folder path or location where ypou want to upload the file.
  • File Name & File Content– Select File name and file content from the dynamic content of Convert file.
How to create pdf without premium action in Power Automate
How to create pdf without premium action in Power Automate

Now our flow is ready to run. Let’s save it and test it manually. Then click on Run flow. It will ask to insert the details like below:

power automate create pdf without premium action
power automate create pdf without premium action

We can see it created a PDF file inside the SharePoint folder:

How to create a PDF without using premium action on Power Automate
How to create a PDF without using premium action on Power Automate

This is how to create a PDF without using premium action on Power Automate.

Power Automate create pdf get file content

Here we will see how to create a PDF using the get file content action with a condition. Let’s take an example when an HR uploads a document in the SharePoint folder it will check whether the document is in PDF or not.

If the document is not in PDF format then it will convert the document into PDF format and upload it to the SharePoint folder. For this, we will create an automated flow and the following steps are:

Step-1: Trigger the flow when a file is created

First, we will trigger the flow when a file is created or uploaded in the SharePoint folder.

Go to Power Automate, click on + Create > Automated cloud flow > Select the trigger When a file is created (properties only). Also, give a name to the flow.

Trigger the flow when a file is created in SharePoint folder
Trigger the flow when a file is created in the SharePoint folder

It will ask to set the below parameters like below:

  • Site Address– Set the SharePoint site address
  • Library Name– Select the document library name
  • Folder– Choose a folder path where you want to upload or create a file.
Power Automate working with File Contents and Files
Power Automate working with File Contents and Files

Step-2: Get the file content

In this step, we will add an action that will get all the file contents using the file identifier. Click on + New step > Get file content. Set the site address and in the file identifier, set Identifier from the dynamic content of the trigger.

create pdf from get file content in Power Automate
create pdf from getting file content in Power Automate

Step-3: Set a condition

Now, we will set a condition that will check whether the file is in pdf format or not. For this, click on + New step > Condition. Set the values and operators such as:

  • Choose a first value: Select the File Name With Extension from the dynamic content of trigger.
  • Operator: select the operator as ‘does not contain’
  • Choose a second value: type ‘.pdf
create pdf using get file content action in Power Automate
create pdf using get file content action in Power Automate

Step-4: Set logic if the condition got satisfied

Next, it will check if the file is not in PDF format then it will convert in PDF format. For this, we will add the logic operations in the If-yes section.

Inside the If yes section, click on +Add an action > Create file. Set the parameters such as:

  • Folder Path– Set Root as folder path.
  • File Name– Select the File Name With Extension from the dynamic content of the trigger.
  • File Content- Select File content from the dynamic content of the trogger.
create pdf get file content using Power Automate
create pdf get file content using Power Automate

Next, we will add an action to convert the file into a PDF file. Go to + Add an action > Convert file(Preview). Here we will set Id from the dynamic content of the ‘create file’ and target type as PDF.

Microsoft flow create pdf get file content
Microsoft flow create pdf get file content

Similarly, we will add an action that will upload the converted PDF file in the specified SharePoint folder.

Go to +Add an action > Create file(under SharePoint). Set the properties like below:

  • Site Address– Set the SharePoint site address.
  • Folder Path– Select a folder path where you want to uplaod the PDFs
  • File Name & File Content– Select file name and file content from the dynamic content of the convert file.
power automate creating pdf from get file content
Power Automate creating pdf from get file content

Next, we will add an action that will delete the temporary file from the one drive using the ID from the dynamic content of the created file.

Go to + Add an action > Delete file(under the One Drive ).

power automate how to create pdf get file content
power automate how to create pdf get file content

In this final step, we will add an action that will delete the previous file(that we uploaded to convert into pdf) from the Sharepoint folder. Click on +Add an action > Delete file(under SharePoint). Set the properties like below:

  • Site Address– set the SharePoint site address.
  • File Identifier– Select the Identifier from the dynamic content of the trigger.
power automate create pdf get file content
Power Automate create pdf get file content

This is what the entire flow looks like:

power automate create pdf from get file content
power automate create pdf from get file content

Let’s save the flow and test it manually. Next, we will upload different kinds of files such as excels, words including pdfs.

Microsoft flow create pdf using get file content
Microsoft flow create pdf using get file content

We can see these files converted to PDF format and stored in the specified folder:

Create pdf from get file content Power Automate
Create pdf from get file content Power Automate

This is how to create a pdf from the get file content Power Automate

Power Automate create pdf from Power BI

Now we will see how to convert the Power BI report into PDF format. For this, we are going to use a connector and its action i.e. Muhimbi PDF. To use this connector, we have to sign up for a free or a trial subscription(for 30 days).

Let’s create a scheduled cloud flow, that will send the Power BI report in PDF format via outlook to the specified user in a time interval.

First, we will upload a Power BI report in a SharePoint folder. Then go to show action. Select Copy link.

power automate convert a Power BI report to PDF
power automate convert a Power BI report to PDF

Then it will show the link of that file from where you can copy the link for further use.

How to convert Power BI Report to PDF using Power Automate
How to convert Power BI Report to PDF using Power Automate

To create a scheduled cloud flow, on Power Automate, go to +create > Scheduled cloud flow > Select it. Set the repeat option as 1 day. Then click on create.

power automate create pdf from Power BI report
Power Automate create PDF from Power BI report

Next, we will add an action under the Muhimbi PDF connector to convert the file into PDF format.

Click on +Next step > search Muhimbi > Select the action Convert HTML to PDF.

Convert Power BI reports to PDF using Power Automate
Convert Power BI reports to PDF using Power Automate

Next, it will ask to set the below properties to activate the action:

  • Source URL or HTML– Paste the copied link
  • Page orientation– set it as Protrait from the dropdown.
  • Media type– Set it as Print from the dropdown.
  • Authentication type– Set it as SharePoint online from the dropdown.
  • User name– Give the user name that we have used to signup
  • Password– Give the password that we have used to get authenticated with the SharePoint online authentication.
  • Conversion delay– Give a delay time for conversion. Set the delay time in milisecond. For example, let’s set it 10000 i.e 10 sec.
Create PDF documents from data in Power Automate
Create PDF documents from data in Power Automate

Next, we will add an action to send the converted PDF to a user. Click on +New step > Send an email (V2). Set the properties like below:

  • To- Set an user ID.
  • Subject- Give a name to the email.
  • Body- Specify teh body and expand it. Give an attachment name using the extension of ‘.pdf‘ and select the Processed file content from the dynamic content of the Convert the HTML to PDF.
Power BI Report Automatically To Email In PDF Format
Power BI Report Automatically To Email In PDF Format

Now we can see the entire flow looks like:

Power BI Automated send Power BI Report as PDF
Power BI Automated send Power BI Report as PDF

Then save the flow and test it manually. We can see the report send in PDF format.

Power Automate send the Power BI report as PDF
Power Automate send the Power BI report as a PDF

This is how to do Power Automate create pdf from Power BI.

Power Automate create pdf without onedrive

From the previous example, we have seen how to create a pdf on Power Automate using OneDrive Convert File Action. But it allows us to create PDFs without using OneDrive. There are some premium connectors by using these we can create PDFs.

Method Complexity Cost
OneDrive Convert File Action Low Free
Plumsail HTML to PDF action Low Not Free
Muhimbi HTML to PDF action Low Not Free
Azure Function Medium Not Free

Also, you may like these below Power Automate tutorials:

Conclusion

From this Power Automate Tutorial, we learned all about how to create PDF using Power Automate flow. Also, we discussed these below topics:

  • How to create pdf free using Power Automate?
  • How to create pdf from html using Power Automate?
  • How to create pdf from SharePoint list items using Power Automate?
  • How to create pdf from word in Power Automate?
  • How to create pdf from Microspoft form using Power Automate?
  • How to create pdf from excel using Microsoft flow?
  • How to create pdf from email using Power Automate?
  • How to create a PDF using without premium action using Power Automate?
  • How to create pdf from get file content in Power Automate?
  • How to create pdf from Power BI using Power Automate?
  • How to create pdf without onedrive using Power Automate?
  • >