← Al Davies, 250 High Street

Convert Word to PDF with Power Automate

Short answer: use the Convert file action from the OneDrive for Business connector. Microsoft lists that connector as Standard in Power Automate. Run it right after a Word file lands in a OneDrive folder, then save the result with a Create file action. If the flow fails with a "not found" style error, the first thing Microsoft suggests is a delay between creating the file and converting it.

This guide shows one way to build that flow, what each setting means, and what to check when it breaks.

What you need before you start

Microsoft's connector page lists OneDrive for Business with the class "Standard" for Power Automate. Microsoft's page does not say what your own license includes, so confirm that with your admin.

What the Convert file action does

Microsoft describes the action in these words: "This operation converts a file to another format. The list of supported conversions can be found at https://aka.ms/onedriveconversions".

The action has two inputs:

  1. File. Microsoft describes it as "The unique identifier of the file."
  2. Target type. Microsoft describes it as "The target file type".

It returns "The content of the file." That content is binary. It is not a saved file yet. You need a second action to save it.

There is also a Convert file using path action, which takes a file path instead of an identifier. Use the one that matches the value your trigger gives you.

Which files can become a PDF

Microsoft's page on converting to other formats says: "Not all files can be converted into all formats." For the pdf format it lists these source extensions: doc, docx, dot, dotx, dotm, dsn, dwg, eml, epub, fluidframework, form, htm, html, loop, loot, markdown, md, msg, note, odp, ods, odt, page, pps, ppsx, ppt, pptx, pulse, rtf, task, tif, tiff, wbtx, whiteboard, xls, xlsm, xlsx. Word files (doc and docx) are on that list.

That page is a Microsoft Graph page, not the connector page, so it may not describe your flow exactly. It also says: "The maximum size limit for files to use format conversion is 2 MB." The connector page does not repeat a number. If your Word files are large, test one before you build the full flow.

The connector page adds one more limit: "The Convert file (Preview) action does not support converting digitally signed, password-protected, or IRM restricted documents from a Microsoft Word document to PDF, due to security reasons."

Build the flow, step by step

Exact names may differ in your tenant, because Microsoft changes menus and action names from time to time.

  1. Open https://make.powerautomate.com and sign in.
  2. Create a new automated cloud flow.
  3. Add the OneDrive for Business trigger "When a file is created". Microsoft describes it as: "This operation triggers a flow when a new file is created in a folder." Pick your Word input folder.
  4. Add a Delay action. Set a short wait. The reason is in the next section.
  5. Add the OneDrive for Business action Convert file. Set File to the file identifier from the trigger. Set Target type to the PDF choice.
  6. Add the OneDrive for Business action Create file. Set Folder Path to your PDF folder. Set File Name to the original name with a .pdf ending. Set File Content to the output of Convert file.
  7. Save the flow and drop one test Word file into the input folder.
  8. Open the run history for the flow and check that every step has a green check.

Microsoft's page for Create file says the file name field works like this: "Certain characters are disallowed by OneDrive and will be replaced by underscores." Keep names simple while you test.

Why "file not found" happens and what to try

Microsoft's connector page lists this under known issues: "If you see an error while converting the file to PDF in the flow (e.g. “Bad gateway” or “The resource could not be found”) using OneDrive for Business connector, the recommendation to workaround this issue would be to increase the delay between the file creation and converting to PDF."

So the first fix is the Delay action from step 4. If you already have one, make it longer and run the test again.

Other things to check. These are our advice, not Microsoft rules, unless a quote is shown:

What to avoid

A simple way to start

One way to start: build the flow for one folder and one test file. When the PDF appears in the output folder, add the extras you need, such as an email with the PDF attached or a copy in a SharePoint library. Our advice, not a Microsoft rule: keep a short list of file names the flow converted, so you can tell later whether a PDF is missing.

For a flow that emails a file, see "My flow email goes out without the attachment". For a flow that moves files between sites, see "Copy a SharePoint file to another site with Power Automate".

When to get help

You can build all of this yourself in Microsoft 365. If you would rather have it built and tested for your team, I do that. A tracker like this is a fixed price: $5,000 for one, built in 2 weeks. See "What a SharePoint tracker costs to build". Bring one example of the problem to a free call.

Tell me what's still manual

I am Al Davies. I run 250 High Street LLC and build SharePoint trackers and Power Automate flows for operations teams. I work remotely. The first call is free, and I will not try to sell you anything.

See trackers I built: Tools I built

FAQ

Can I convert Word to PDF in Power Automate without a premium license?

Microsoft's connector page lists OneDrive for Business as "Standard" for Power Automate, and the Convert file action is part of that connector. Microsoft's page does not state what your own plan includes, so check with your admin.

Why does Convert file say the file cannot be found?

Microsoft's known-issues list names "The resource could not be found" and suggests a longer delay between creating the file and converting it. Add or lengthen a Delay action first, then check the file identifier or path.

Can it convert a password-protected Word file?

No. Microsoft states that the Convert file (Preview) action does not support digitally signed, password-protected or IRM restricted documents, "due to security reasons".

Is there a size limit?

The Microsoft Graph page on format conversion says the maximum size is 2 MB. The connector page does not repeat that number, so test with your largest typical file.

Can I convert a file that is in SharePoint instead of OneDrive?

The action described here is in the OneDrive for Business connector. Our advice, not a Microsoft rule: if your files are in a SharePoint library, copy a test file to OneDrive for Business and confirm the flow works there before you build around it.

Sources