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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / Power Automate Excel R...
Power Automate
Suggested Answer

Power Automate Excel Run Script Error 502 BadGateway

(0) ShareShare
ReportReport
Posted on by

I have multiple flows that run scripts in Excel with no errors, and yesterday they all started failing with error code 502 "BadGateway."

  • I verified that involved files are not read-only.
  • I am able to manually run the scripts in the workbooks (in Excel Online and Excel Desktop).
  • I tried refreshing + adding a new connector and relinking to actions.
  • I tried copy/paste-ing to create new actions with the new connector.
  • I tried re-saving scripts to Sharepoint and calling the action "Run Script from Sharepoint"

Any ideas for how to troubleshoot? Why else might the flow be getting stuck trying to run scripts?

Categories:
I have the same question (0)
  • Suggested answer
    BCBuizer Profile Picture
    22,752 Super User 2026 Season 1 on at
     
    Another user reported a similar issue and fix that worked for them: https://learn.microsoft.com/en-us/answers/questions/5903740/how-to-fix-502-error-in-power-automate
     
    I suggest you try the same fix.
     
     
    If this reply helped you in any way, please give it a Like 💜 and in case it resolved your issue, please mark it as the Verified Answer ✅.

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!

Congratulations to the April Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
Vish WR Profile Picture

Vish WR 632

#2
Haque Profile Picture

Haque 458

#3
Valantis Profile Picture

Valantis 357

Last 30 days Overall leaderboard