AutomateAlong

How-tos › Build a flow

How to move emails to a folder automatically with Power Automate

Updated 2 November 2026

What this flow does: Move incoming emails with 'invoice' in the subject into an Invoices folder. When it works: Invoice emails appear in your Invoices folder instead of the Inbox.

Before you start

  • A Microsoft 365 account that can open make.powerautomate.com.
  • Connections to: Office 365 Outlook. Power Automate asks you to sign in to each the first time you add a step from it.
  • An Invoices folder already exists in your mailbox.

The flow at a glance

  1. When a new email arrives · When a new email arrives (V3)
  2. Is it an invoice · Condition
  3. If yes: Move to Invoices folder · Move email (V2)

Rename each step to the name shown. Expressions refer to steps by name, so a different name breaks them.

Build it step by step

1. When a new email arrives · Office 365 Outlook → When a new email arrives (V3)

Starts for each new email.

In Power Automate, select Create, then the flow type (Automated cloud flow), name it, and choose this trigger.

BoxValueHow it goes in
Folder
Choose from the dropdown
InboxOpen the dropdown and choose "Inbox".
Include Attachments
Choose from the dropdown
NoOpen the dropdown and choose "No".

2. Is it an invoice · Control → Condition

Looks for 'invoice' in the subject.

Select + below the previous step, then Add an action, search for Control and select Condition. Rename it to Is it an invoice.

BoxValueHow it goes in
Left value
Expression, in the fx box
toLower(triggerOutputs()?['body/subject'])Click in the box, select the fx (Expression) button, paste it into the expression box, then select Add. Don't type it as plain text.
Operator
Choose from the dropdown
containsOpen the dropdown and choose "contains".
Right value
Type or paste it
invoiceClick in the box and paste it.

3. Move to Invoices folder · Office 365 Outlook → Move email (V2)

Moves the email.

Select + below the previous step (if yes), then Add an action, search for Office 365 Outlook and select Move email (V2). Rename it to Move to Invoices folder.

BoxValueHow it goes in
Message Id
Dynamic content
⚡ Message IdClick in the box, select the lightning-bolt (Dynamic content) button, then under the trigger pick "Message Id".
Folder
Your own site, list or folder
InvoicesPick your own from the dropdown (for example: Invoices).

Test it

  1. Select Save, then Flow checker and fix anything it lists.
  2. Select Test → Manually → Test, then do the thing that starts the flow (send the email, submit the form, or run it).
  3. Open the run and check every step has a green tick. Then check the result: Invoice emails appear in your Invoices folder instead of the Inbox.
  4. If a step has a red cross, select it, copy the error and paste it into the Flow Doctor.

Things to watch

  • A simple Outlook rule can also do this. Use a flow when you want extra steps later.

Or let AutomateAlong build it alongside you

This flow is a template in AutomateAlong: open it in the builder and it walks you through the same steps one at a time, with a Copy button on every value, readiness checks, and improvement ideas (error handling, duplicate checks) you can add with one click. Free, no card needed.

Related

AutomateAlong is independent and isn't affiliated with Microsoft. Microsoft and Power Automate are trademarks of the Microsoft group of companies.