Showing results for 
Search instead for 
Did you mean: 
Helper II
Helper II

Flow error- HTTP status code 504 Gateway Timeout

Hi, I keep getting these email from flow that my flow has failed but when i look in to the flow history I do not see any failed flow instance form this week. The flow works most of the times but has 3-4 failed instances in last month. I am not using any gateway or on-prem connection in the flow.


The latest failed instance I see if from a week ago with the following error-


"The execution of template action 'Respond_to_PowerApps' is failed: the client application timed out waiting for a response from service. This means that workflow took longer to respond than the alloted timeout value. The connection maintained between the client application and service will be closed and client application will get an HTTP status code 504 Gateway Timeout."


Any suggestion, what could be causing this error?


This flow is using powerapps template to check user permissions in a sharepoint group, if the user is SP group A they can see the the full PowerApp form with all fields, and if the user is in Group B they can only see limited fields in powerapps.


Any ideas/suggestions are welcome.

Community Support
Community Support


Hi @anka ,


It seems that this seems to be a temporary error, please try to update the connection of the corresponding action or re-create the connection, and then re-submit the Flow.


If the problem persists, please provide a screenshot of the Flow configuration so that we can do a more accurate analysis.


Best Regards,

Community Support Team _ Barry
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Advocate I
Advocate I

Hi Anka. 

We are facing the same issue right now, for us it seems that it is due to there is a very short limit on how long a flow can run before the 'respond to power apps' times out. 
The only 'documentation' I could find was this:

I'm currently facing it when my flow runs for more than 95 seconds. 

I am getting the same error as well.  It seems any flow running longer than 2 min will not be able to send a response.


I do know there is options for an asynchronous response, but there is no documentation on the  Response action that describes how to setup or use this functionality and instead only has a vague description of its capabilities.

If further clarification could be done about either the asynchronous response and/or ability to change the timeout value that would be great.

Advocate I
Advocate I

Nowadays (since the COVID-19 pandemic started) this is very common and the weird thing is this:timeout.png

The whole runtime of an “Apply to each” action took 4 minutes, while it only had a single sub action which took zero seconds, and the number of items to loop through is one

If my math is correct, one times 0 seconds is 0 seconds.

@gergoeWhen you use controls like "Apply to Each" it creates sub-processes, or internal sub-flows to handle each loop.  The delay could be the time it takes to allocate these resources.  I have also seen that it can be very inefficient at times.

There's a blog post on the Response action by the very fabulous Brian Dang here:


I found the video very helpful, and I got the Response action working.  BUT!... it didn't help at all with the timeout issue I'm afraid.

@ThreeTen Do you have a recommendation for how to handle the need to loop through an indeterminate amount of steps (i.e. each Sales Order can have 1 to many Sales Lines)?


And if this works 99% of the time and literally can fail on a single loop it seems the inefficiency is the overall platform and not the Flow. 


Any advice is greatly appreciated.

Resolver I
Resolver I

I have a flow that fails several times a week but not every time it runs.  It typically takes 4 s to run so its not a time out issue.  I have a PowerApps form that triggers the flow to run.  I'm wondering, if a user closes the form before the flow responds to the form request, if that would cause this error message?  If it does what can I do to handle the error?

Helpful resources

Power Automate News & Announcements

Power Automate News & Announcements

Keep up to date with current events and community announcements in the Power Automate community.

Community Calls Conversations

Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Automate Community Blog

Power Automate Community Blog

Check out the latest Community Blog from the community!

Users online (2,379)