web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Is it possible to crea...
Power Automate
Answered

Is it possible to create a folder flow that self-deletes content?

(1) ShareShare
ReportReport
Posted on by 3

Hello, 
New to Power Automate and looking for some guidance. 

 

Is it possible to create a Flow that will allow a folder to self-delete it's content? 

For example, every day at 9pm, no matter what is in the folder, everything will be deleted.

 

Would this simply send the files to the Recycle Bin or will this permanently delete the files?

 

Thank you for the help

Categories:
I have the same question (0)
  • Verified answer
    v-qiaqi@microsoft.com Profile Picture
    Microsoft Employee on at

    Hi @VWP5

    Use the recurrence as the trigger by setting every day at 9pm.

    vqiaqimsft_3-1691553513424.png

     

    vqiaqimsft_4-1691553552522.png

    Note that Shared Documents/Temp/ is my folder path, please replace it with yours.

    item()?['{Identifier}']

    Under this Filter array action, we will add an ‘Apply to each’ action for looping where we will use the body as output from the previous step i.e. from the Filter array.

    vqiaqimsft_1-1691552517025.png

    The above flow will move all the files into the recycle bin as below:

    vqiaqimsft_2-1691553498014.png

     

     

     

  • sandeepstw Profile Picture
    312 Moderator on at

    Hi There, 

    Yes, you can. Use a "Recurrence" trigger to set the frequency of the flow to run every day at 9pm. Use the "Get files (properties only)" or "Get files (metadata only)" action to get all the files in the specified folder. Use an "Apply to each" control to iterate through each file. Use the "Delete file" action inside the loop to delete each file.

     

    Please give kudos and mark as solution if it helps.  

      

    Thanks, 

    Sandeep Mishra 

  • VWP5 Profile Picture
    3 on at

    Thank you 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Leaderboard > Power Automate

#1
trice602 Profile Picture

trice602 239 Super User 2026 Season 1

#2
David_MA Profile Picture

David_MA 177 Super User 2026 Season 1

#3
Kalathiya Profile Picture

Kalathiya 97 Super User 2026 Season 1

Last 30 days Overall leaderboard