Check IF Attachment Exists Using Power Automate

Have you ever needed to check if an attachment exists before taking action in Power Automate? I faced this requirement in an Expense Management System product, where I had to ensure receipts were attached before processing expense claims.

In this tutorial, I will show you how to check if attachment exists using Power Automate in three cases. Such as:

  1. Check if attachment exists in an email using Power Automate
  2. Power Automate check if an attachment exists in a SharePoint list
  3. Check if an attachment exists when a Microsoft Form is submitted using Power Automate

Check IF Attachment Exists Using Power Automate

Suppose you want to create a Power Automate flow that triggers when a new email arrives in Outlook. The flow should save the email to a SharePoint document library if the email contains an attachment. If no attachment is present, the flow should take no action.

I used the below SharePoint Document library:

Power Automate Condition IF the Attachment Exists in Email

To do this, follow the below steps:

1. Create an automated cloud flow with a trigger, When a new email arrives (V3), then you can expand the Advanced parameters, add some filter in my I do want any:

power automate check if attachment exists

2. Add a Condition to Check for Attachments:

  • In the left input, Select Has Attachments from the dynamic content of the email trigger.
  • Set the condition as is equal to.
  • In the right input, enter true.
power automate check if email attachment exists

3. In the true section add Create file action from SharePoint connector and provide the below parameters:

  • Site Address: Select the site address where your library is located.
  • Folder Path: Choose the Library name.
  • File Name: Select the Attachment Name from dynamic content. Then it will add a For each loop in the create file action.
  • File Content: Select the Attachment Content from dynamic content.
When a new email arrives (v3) issue with Has Attachment in Power Automate

Now save the flow and run the flow manually. Then send an email to the other account to this account.

Power Automate Email Attachments save

After the flow runs successfully, go to the SharePoint document library, refresh it, and you will see the attachment saved in the library.

Condition IF the Attachment Exists in Email using Power Automate

This way you can check if the attachment exists in an email.

Check IF Attachment Exists in SharePoint List Using Power Automate

You have a SharePoint list where users submit requests, sometimes with attachments. You want to automate a process where Power Automate checks if an item has an attachment:

  • If an attachment exists: Send an email notification confirming the attachment.
  • If no attachment exists: Send a different email notifying the user to upload an attachment.

For this example, I use a SharePoint list called Expense Claims with the columns:

CoolumnsData Types
Claim IDSingle line of text
Employee NamePerson or Group
Total AmountNumber
AttachmentsDefault Column
Validate SharePoint List Item Attachments in Power Automate

Now follow the below steps:

1. Create an Automated Cloud Flow using the SharePoint connector’s ‘When an item is created or modified‘ trigger. Select the SharePoint site where your ‘Expense Claims‘ list is present, and choose the ‘Expense Claims‘ list.

Sharepoint list check for attachments using Power Automate

2. Add a Condition action to Check for Attachments:

  • In the left input, Select Has Attachments from the dynamic content of the email trigger.
  • Set the condition as is equal to.
  • In the right input, enter true.
Power Automate Condition IF the Attachment Exists in SharePoint List

3. In the true section, add a Send an Email (V2) action to notify the requester.

  • To: Provide the Employee email address.
  • Subject: Attachment Received for Your Request
  • Body: Provide the below:
Dear @{triggerBody()?['EmployeeName/DisplayName']},

We have received your request along with the necessary attachment. Our team will review it and get back to you shortly.

If you need any further assistance, please feel free to reach out.

Best regards,
TSINFO TECHNOLOGIES PVT LTD
How to check if SharePoint attchment already exists in Power Automate

4. In the False section, add a Send an Email (V2) action to send a confirmation email to the customer.

  • To: Provide the employee email column from dynamic content.
  • Subject: No Attachment Found – Action Required
  • Body: Provide the below:
Dear @{triggerBody()?['EmployeeName/DisplayName']},

We noticed that your request was submitted without an attachment. If an attachment is required, please update your request and upload the necessary file as soon as possible.

If you have any questions or need assistance, feel free to contact us.

Best regards,
TSINFO TECHNOLOGIES PVT LTD
Power Automate Condition IF the Attachment Exists SharePoint List

Save the flow, go to the SharePoint list, and add an item without the attachment.

Power Automate Validate SharePoint List Item Attachments

After the flow run successfully, the requester will receive an email about No Attachment Found.

Condition IF the Attachment Exists in SharePoint List using Power Automate

Check IF Attachment Exists in Microsoft Form Using Power Automate

You have a Microsoft Form where employees submit expense reimbursement requests. The form includes a file upload field for supporting documents (receipts, invoices, etc.).

Verify if a Microsoft Form has an attachment in Power Automate

You want to create a Power Automate flow that:

  • Checks if the form submission includes an attachment.
  • If an attachment exists, save it to a SharePoint document library.
  • If no attachment exists, send an email to the submitter, asking them to upload the required documents.

To do this, follow the below steps:

1. Create an automated cloud flow. Give the flow name and select the trigger When a new response is submitted. Also, provide the Form ID, which, in my case, is the Expense Reimbursement Requests.

How do I check if a file exists in Form using Power Automate

2. To retrieve the response, add the Get response details action from the Microsoft Forms connector. Then, provide the Form ID from the dropdown menu and select the Response ID from the dynamic content of the When a new response is submitted trigger.

Can you include attachments in Microsoft Forms using Power Automate

3. Add a Condition action to Check for Attachments:

  • In the left input, Select Upload Receipt from the dynamic content of the email trigger.
  • Set the condition as is not equal to.
  • In the right input, enter “”.
How to set up a Condition in Power Automate flow to check if form has attachments

4. In the true section, add a compose action and provide the expression below, like json Upload Receipt from the dynamic content.

json(Upload Receipt from the dynamic content)
Power Automate Tutorial Microsoft Forms Attachments

5. Then add an Apply to each action, and in the Select an output from previous steps, provide the output of the Compose nation from dynamic content.

Add attachments from Forms to Microsoft Lists using Power Automate

6. Inside the Apply to each action add Get file content action from OneDrive for Business Connector and provide the below expression in the File parameter:

item()?['id']
MS Form Data to SharePoint with Optional attachments

7. Then add Create file action and provide the below parameter:

  • Site Address: Select the SharePoint site address from the dropdown menu where you want to store the attachments.
  • Folder Path: Select the folder path.
  • File Name: Provide the below expression:
item()?['name']
  • File Content: Use the dynamic content File Content from the Get file content action.
Save multiple attachments and files from Microsoft Forms to a SharePoint library with Power Automate

8. In the False section, add a send an email (V2) action and provide the below parameters:

  • To: Provide the Employee email address.
  • Subject: Action Required: Missing Attachment in Your Expense Reimbursement Request
  • Body: Provide the below:
Hello @{outputs('Get_response_details')?['body/rf467c52058ee4e3b985aaaa91c7207c6']},

We received your expense reimbursement request, but it looks like you didn't attach any supporting documents (receipts, invoices, etc.). These documents are required to process your request.

Best regards,
TSinfo Technologies Pvt. Ltd.
Check IF the Attachment Exists using Power Automate

Now save the flow and run it manually. Then, go to the Microsoft form and fill it out without an attachment.

Check IF the Attachment Exists in Microsoft Form using Power Automate

After the flow runs successfully, the employee receives the following email:

How to Check IF the Attachment Exists in Microsoft Form using Power Automate

Conclusion

In this tutorial, we explained how to check for attachments in Power Automate across different scenarios. We started by checking if an email contains an attachment and saving it to a SharePoint document library.

Then, we looked at verifying attachments in a SharePoint list and sending email notifications based on their presence. Finally, we covered how to check for attachments in a Microsoft Form submission, store them in SharePoint, or notify the submitter if they were missing the attachment.

Moreover, you may like some more Power Apps tutorials:

Power Apps functions free pdf

30 Power Apps Functions

This free guide walks you through the 30 most-used Power Apps functions with real business examples, exact syntax, and results you can see.

Download User registration canvas app

DOWNLOAD USER REGISTRATION POWER APPS CANVAS APP

Download a fully functional Power Apps Canvas App (with Power Automate): User Registration App