A client recently reached out with a requirement in Power Automate Desktop. They needed to upload an Excel file containing employee details from their local system to a SharePoint document library, along with the associated metadata. Additionally, they wanted the entire process to be automated using Power Automate Desktop.
In this tutorial, I will explain how to upload various file types to a SharePoint document library using Power Automate Desktop. Also, I will cover:
- Create a file within the SharePoint folder using PAD
- Adding Metadata to the created file using Power Automate Desktop
Upload Files to SharePoint from Power Automate Desktop
Let’s explore how to upload various file types to a SharePoint document library using Power Automate Desktop.
In the Power Automate Desktop app, SharePoint is a ‘Premium’ feature that can only be accessed by having a free trial or a Power Automate license.
To upload the file to SharePoint using PAD, we need to use the ‘Create File‘ action. This action will receive the file in binary format. So, we need to convert the file into a binary data format.
Example 1: Upload Excel File to SharePoint Power Automate Desktop
Below, you can see that the Excel file contains employee details, i.e., Employee ID, Name, Department, Position, Salary, and Hire Date.

I wanted to upload the above Excel into the SharePoint document library.
For this example, I created a SharePoint document library named “Employee Documents”.

Now, follow the steps below:
- Open the Power Automate Desktop app, click on +New, and select the Flow option. Provide the flow name and click Create. Then, add actions to the workspace.
- Next, I will convert the Excel data to binary. To do this, drag and drop the “Convert file to binary” action into the workspace. Set the parameter below:
- File path: Click ‘Select File’ icon -> Choose Excel file from your system.

- Then, expand the ‘SharePoint‘ section and drag and drop the ‘Create File’ action. Configure the parameters below:
- Site address: Select the SharePoint site address where you want to create the file.
- Folder path: Select the Folder path by clicking on the Select file option.
- File name: Provide the file name with extension. Here, I’m taking the (.xlsx) file.
- File content: Click on the {x}, select the BinaryData variable, and click Save.

- Now run the flow by clicking on the Run button. You can see that the Excel file has been uploaded to the SharePoint document library.

Example 2: Upload CSV File to SharePoint Library using Power Automate Desktop
In this section, we will explore how to upload a CSV file to the document library in SharePoint using Power Automate Desktop.
You can view the screenshot below, which displays the SharePoint document library with a Folder and one .xlsx file.

Now, I will upload the CSV file named ‘Employee Performance Appraisal’ into the SharePoint document library.
You can follow the same steps as mentioned in Example 1.
- On to the workspace, add the ‘Convert file to binary data’ action and set the file path.

- To upload the file, drag and drop the ‘Create File’ action from the SharePoint connector and set the required parameters, such as Site address and Folder path.
- File name: Enter file name along with the .csv extension.
- File content: Select the BinaryData variable from the previous step.

Now, the flow is ready. Click “Save” and then run the flow.
- When the flow execution is successful, go back to the SharePoint library. You can find the uploaded .csv file.

Power Automate Desktop: Create a File within a SharePoint Folder
Let me explain how to upload a file within a SharePoint document library folder using Power Automate Desktop.
In the image shown below, you can see a Folder ‘Document Management System’ in the SharePoint document library.

I wanted to upload a Word file named ‘Employee Documents Guidelines’ to this folder.
Check out the steps below:
- Similarly, add the ‘Convert file to binary‘ action and set the file path that will convert the file data into binary format.

- Next, choose to add the ‘Create File’ action from the SharePoint connector and set the required parameters, and save the action.
- Site address: Select the SharePoint site address from the drop-down.
- Folder path: Select the folder level path from the drop-down.
- File name: I have provided the file name with the .docx extension.
- File content: Select the EmployeeGuidelines variable from the previous step.

- When the flow runs successfully, you can see that the Word file has been uploaded to the SharePoint folder.

This way, you can upload different types of files to the SharePoint library using PAD.
Add Metadata to a SharePoint File using Power Automate Desktop
In the previous sections, you might have learned how to upload a file to a SharePoint library. Here, I will show you how to add metadata to the created file using PAD.
I have created a SharePoint document library ‘Employee Documents’ that has columns as given in the table below.
| Column Name | Data Type |
|---|---|
| Department | Choice |
| Expiry Date | Date and Time |
| Validity Period | Single line of text |
| Remarks | Multi lines of text |
| Confidentiality level | Choice |
| Approver | Person or Group |

Now, let’s see how to upload a file named ‘Employee Joined 2025’ along with the file properties. First, we need to upload a file to SharePoint and then update the file properties.
Below are the steps to do this:
- On the first step, drag and drop the ‘Convert file to binary data’ action to convert the file into binary data format.

- After that, I’m adding a ‘Convert text to datetime’ action that will convert the text into a date value to input into the SharePoint date column.

- Next, choose to add the ‘Create File’ action from the SharePoint connector and set the required parameters like Site Address, Folder Path, File Name, and File Content. Click on the Save button.

- In the final step, drag and drop the ‘Update file properties’ action from the SharePoint connector. This action updates the SharePoint columns in a library for the specific item.
- Site Address: Select the site address from the drop-down.
- Library Name: Choose the Library name from the options.
- Id: Click on {X} -> Select %CreateFileResponse.itemId% variable.
- Expiry Date: Choose Date variable.
- Validity: Provide the value.
- Remarks: Enter the value according to your requirement.
- Department Value: Choose the value from the drop-down.
- Confidentiality Level Value: Select the value from the drop-down.
- Approver Claims: You can provide an email or the name of the approver.

After that, click on the Save button to save the action. Run the flow.
- When the flow executes successfully, you can see that the file has been uploaded with the metadata in the SharePoint library.

This guide explains how to upload and update file properties in SharePoint using Power Automate Desktop.
While uploading a file to SharePoint with the ‘Create file’ action, you must provide the right extension next to the file name; otherwise, the file content will not be shown.
Read Other Power Automate Desktop Tutorials:
- Power Apps Bulk Approvals Using Power Automate
- Find and Replace Text in Power Automate Desktop
- Update Data Table Items Power Automate Desktop
- Get Values from Data Table Power Automate Desktop
- Power Automate Send Reminder Emails

Preeti Sahu is an expert in Power Apps and has over six years of experience working with SharePoint Online and the Power Platform. She is the co-author of Microsoft Power Platform: A Deep Dive book. As a Power Platform developer, she has worked on developing various tools using Power Apps and Power Automate. She also makes Microsoft 365 videos and shares them on YouTube.