- Home
- Guides
- Power Automate
- How to back up Outlook emails to OneDrive automatically with Power Automate
How to back up Outlook emails to OneDrive automatically with Power Automate
Build a three-step Power Automate flow that saves every new Outlook email, attachments included, as an .eml file in a OneDrive folder, named with the subject and sender.
Jump to a step (6)
Client conversations, invoices and project updates often live only in a mailbox. If you want a separate copy, most people drag emails to a folder by hand or buy a backup tool. This flow does it in the background for each new message, using standard Microsoft 365 connectors.
The flow runs every time a new email arrives. Export email (V2) gets the full message, including attachments, and Create file writes it to OneDrive for Business as an .eml file. You can open that file later in Outlook or any email app.
You can back up every email, or add trigger filters to save only mail from a certain sender, with a certain subject, or with attachments.
What you need
- Microsoft 365 Business Basic or Standard
- Power Automate (standard connectors only)
- An Office 365 Outlook mailbox
- A OneDrive for Business folder for the backups
Step by step
0 of 6 done-
01
Create an automated cloud flow
In Power Automate, go to My flows, click New flow and choose Automated cloud flow. Name it (in the video: Backup Outlook Emails). Search for
emailand pick When a new email arrives (V3) from Office 365 Outlook, then click Create.There is a separate trigger for free Outlook.com accounts. Use the Office 365 Outlook one for a work mailbox.
-
02
Add optional filters to the trigger
Open Advanced parameters on the trigger to limit what gets backed up. For example, set From to one sender's address, filter by subject, or only include emails with attachments. Leave them empty to back up every email.
-
03
Export the full email
Add the Office 365 Outlook action Export email (V2). For Message Id, open the dynamic content, click See more under the trigger and pick
Message Id. This returns the complete message, including attachments. -
04
Save the email to OneDrive
Add the OneDrive for Business action Create file. Sign in if prompted. For Folder Path, use the folder picker to select your backup folder (in the video:
/Email Backup).Build the File Name from dynamic content:
Subjectfrom the trigger, a dash,Fromfrom the trigger, then type.emlat the end. The file must end in.emlso it opens as an email. You could also addReceived Timeto the name.For File Content, pick
Bodyfrom Export email (V2). Save the flow. -
05
Test the flow
Click Test, choose Manually and click Test again. Send an email with an attachment to the mailbox. When the flow run succeeds, refresh the OneDrive folder. You will see a file named with the subject and sender.
-
06
Open the backup in Outlook
OneDrive shows the message text, but to open attachments, download the
.emlfile and open it with Outlook or another email app. Double-click the attachment inside to view it.
Tips and common problems
- Use the Office 365 Outlook trigger When a new email arrives (V3) for work accounts. Free Outlook.com accounts have their own trigger.
- The file name must end with .eml or the backup will not open as an email.
- Include the subject and sender in the file name so you can find emails later without opening them.
- OneDrive's preview does not let you open attachments. Download the .eml file and open it in Outlook to see them.
- To keep a copy on your hard drive too, sync the OneDrive backup folder to your computer.
The flow at a glance
| Step | Connector and action | Key setting |
|---|---|---|
| Trigger | Office 365 Outlook: When a new email arrives (V3) | Optional filters under Advanced parameters |
| 2 | Office 365 Outlook: Export email (V2) | Message Id from the trigger |
| 3 | OneDrive for Business: Create file | File Name ends in .eml, File Content = Body from Export email |
Only need the attachments? See download every Outlook attachment into one folder.
Questions
Can Power Automate back up Outlook emails automatically?
Yes. An automated cloud flow with the When a new email arrives (V3) trigger, the Export email (V2) action and the OneDrive for Business Create file action saves each new email as an .eml file. All three are standard connectors.
Does the .eml backup include attachments?
Yes. Export email (V2) exports the full message, so attachments are included. Download the .eml file and open it in Outlook to view them.
Why does the Create file step fail for some emails?
OneDrive file names cannot contain certain characters such as a colon or question mark, and subjects like "RE: Invoice?" include them. If you see failures on replies or forwards, remove those characters from the subject before using it in the file name.
Can I back up only emails from one sender?
Yes. Open Advanced parameters on the trigger and enter the sender's address in the From field. You can also filter by subject or only include emails with attachments.
