In Power Automate Desktop (PAD) there’s no built-in “auto-kill after X minutes” setting, so you have to enforce the 10-minute limit yourself. Here are the three reliable ways, from best practice to more advanced.
Best practice: Control it from a Cloud Flow (recommended)
This is the cleanest and safest approach.
How it works
-
A Cloud flow starts the Desktop flow
-
You set a timeout of 10 minutes
-
If the desktop flow runs longer → it gets terminated automatically
Steps
-
Create a Cloud flow
-
Add action: Run a flow built with Power Automate for desktop
-
Click … (three dots) on the action → Settings
-
Set Timeout to:
-
Enable Run in unattended mode if needed
-
Save
If the desktop flow exceeds 10 minutes, Power Automate will force stop it
Pros
-
Official, supported
-
No hacks
-
Best for production
Option 2: Build a timeout watchdog inside the Desktop Flow
Use this if you must run PAD standalone.
Basic logic
-
At the start of the flow, store the current time
-
During loops or long actions:
-
Check elapsed time
-
If > 10 minutes → Terminate flow
-
Example logic
-
Action: Get current date and time →
StartTime -
Inside loops:
-
Get current date and time →
Now -
Subtract datetimes
-
If
ElapsedMinutes > 10:-
Use Terminate flow action
-
-
Pros
-
Works offline
-
No cloud flow needed
Cons
-
Only stops at checkpoints (not mid-action)
Option 3: Force-kill the process (advanced / last resort)
You can externally kill PAD if it hangs.
Method
-
Use another flow / scheduled task to run:
or
Cons
-
Abrupt stop
-
Can corrupt sessions
-
Not recommended unless recovery automation is required
Comments
Post a Comment