Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
Summary
This article helps you fix Power Automate browser extension issues that affect web automation in desktop flows, including the "Failed to assume control of browser (Internal error or communication failure)" error and the "You need the Power Automate extension" message. It covers the PAD.BrowserNativeMessageHost.exe process, native messaging policies in Microsoft Edge, Google Chrome, and Mozilla Firefox, blocked cmd.exe execution, multiple browser profiles, and conflicting MSI and MSIX installations.
Symptoms
You experience the following symptoms:
At runtime, the browser automation group takes an action that fails and returns the following error message:
Failed to assume control of browser (Internal error or communication failure).
Note
In this message, browser represents the name of the web browser, such as Microsoft Edge or Google Chrome.
During the design phase, when you open the UI element picker or the recorder and hover the mouse over a webpage, the following message is displayed:
You need the Power Automate extension.
Prerequisites
Make sure that the Power Automate web extension is installed and enabled in your browser.
Make sure that the correct Power Automate web extension is installed and enabled in your browser. Install only one of the following extensions:
- For Power Automate for desktop v2.27 or later versions, use the Microsoft Power Automate extension.
- For Power Automate for desktop v2.26 or earlier versions, use the Microsoft Power Automate (Legacy) extension.
For more information, see Install Power Automate browser extensions.
Resolution
To troubleshoot and resolve the issue, use the steps in the following sections.
Check whether PAD.BrowserNativeMessageHost.exe is running for your browser
Follow these steps:
Close all open browser windows.
Open the browser that you use in your desktop flow.
Open Windows Task Manager, select the Details tab, and then verify that
PAD.BrowserNativeMessageHost.exeis running.Note
One instance of this process runs for each browser type.
If PAD.BrowserNativeMessageHost.exe isn't running, follow these steps:
Check whether the Power Automate web extension is installed and enabled. If it's not installed, see the Prerequisites section.
If the extension is installed, run the Troubleshoot UI/Web automation issues diagnostic in Power Automate for desktop troubleshooter.
Follow the steps that are suggested in the troubleshooter.
Look for errors in the background script
Note
This step applies only to Microsoft Edge and Google Chrome.
Follow these steps:
Go to the appropriate extension page:
- Microsoft Edge:
edge://extensions/ - Google Chrome:
chrome://extensions/
- Microsoft Edge:
Turn on Developer mode.
Find the Microsoft Power Automate extension.
Select background.html for the Microsoft Power Automate (Legacy) browser extension or service worker for the Microsoft Power Automate browser extension. This step opens the developer tools.
Check for any errors on the Console tab.
The error message, "Access to the native messaging host was disabled by the system administrator," indicates that the NativeMessagingBlocklist policy is enabled for the Power Automate for desktop native messaging host or all native messaging hosts.
Check for policies that block the message host
Follow these steps:
Go to the appropriate extension page:
- Microsoft Edge:
edge://policy/ - Google Chrome:
chrome://policy/
- Microsoft Edge:
Check the NativeMessagingBlocklist policy. If you enable this policy for all native messaging hosts, add the Power Automate for desktop native messaging host to the NativeMessagingAllowlist policy:
Open Start, enter Registry Editor, and then select Registry Editor in the results.
Create the NativeMessagingAllowlist policy if it doesn't already exist, and then add the Power Automate for desktop native messaging host.
For the Microsoft Power Automate (Legacy) browser extension, follow these steps for your preferred browser.
To add a policy at the local machine level:
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge\NativeMessagingAllowlist Name = {number} Data = com.robin.messagehostTo add a policy at the current user level:
Computer\HKEY_CURRENT_USER\SOFTWARE\Policies\Microsoft\Edge\NativeMessagingAllowlist Name = {number} Data = com.robin.messagehostFor the Microsoft Power Automate browser extension, follow these steps for your preferred browser.
To add a policy at the local machine level:
Computer\HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Edge\NativeMessagingAllowlist Name = {number} Data = com.microsoft.pad.messagehostTo add a policy at the current user level:
Computer\HKEY_CURRENT_USER\SOFTWARE\Policies\Microsoft\Edge\NativeMessagingAllowlist Name = {number} Data = com.microsoft.pad.messagehostCheck the NativeMessagingUserLevelHosts policy. If NativeMessagingUserLevelHosts is disabled, enable it or make sure that
com.robin.messagehostfor the legacy browser extension andcom.microsoft.pad.messagehostfor the default browser extension are added to your NativeMessagingAllowlist policy in HKLM (Local Machine level).Note
You must enable NativeMessagingUserLevelHosts when using the Microsoft Store (MSIX) version of Power Automate for desktop.
Check whether the message host points to the correct location
Follow these steps:
Close and reopen Power Automate for desktop. (Also, close the Power Automate console from the Windows task bar before you reopen it.)
Open Registry Editor.
Navigate to the following registry subkeys:
For the Microsoft Power Automate (Legacy) browser extension:
Computer\HKEY_CURRENT_USER\SOFTWARE\Microsoft\Edge\NativeMessagingHosts\com.robin.messagehostFor the Microsoft Power Automate browser extension:
Computer\HKEY_CURRENT_USER\SOFTWARE\Microsoft\Edge\NativeMessagingHosts\com.microsoft.pad.messagehost
Check the value of the registry key. The correct value is as follows:
MSI:
C:\Program Files (x86)\Power Automate Desktop\dotnet\PAD.ChromiumManifest.jsonMSIX Windows 11:
C:\Program Files\WindowsApps\Microsoft.PowerAutomateDesktop_X.Y.Z.0_x64__8wekyb3d8bbwe\PAD.ChromiumManifest.jsonTo retrieve
X.Y.Z:Select Start, search on Power Automate, and then right-click its icon.
Select App settings.
Retrieve the value from Version. In the following example, the values are
X=10,Y=0, andZ=5396.
MSIX Windows 10:
AppData\Local\Packages\Microsoft.PowerAutomateDesktop_8wekyb3d8bbwe\TempState\webextensions\PAD.ChromiumManifest.json
Check whether cmd.exe execution is disabled
Power Automate for desktop relies on the browser extension to communicate with the native messaging host. If Group Policy, Intune, or registry restrictions block cmd.exe execution, the browser can't launch the native messaging host, and the Power Automate browser extension might fail.
Restoring access to cmd.exe ensures that the browser can correctly launch the native messaging host that's required by the Power Automate browser extension. To re-enable cmd.exe, use one of the following methods.
Re-enable cmd.exe by using Group Policy
- Press Win+R, enter
gpedit.msc, and then press Enter. - Go to User Configuration > Administrative Templates > System.
- Open Prevent access to the command prompt.
- Set the policy to Disabled or Not configured.
- Select OK to save the changes.
Re-enable cmd.exe by using Registry Editor
- Open Start, search for and select Registry Editor.
- Go to
HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\System. - Find the
DisableCMDvalue, and then do one of the following:- Set the value to
0. - Delete the value.
- Set the value to
Check for the ComSpec variable
Check whether the ComSpec variable exists in Environment variable under System variables. If it doesn't exist, add it, and then try again:
Select Start, search for Environment variables, and then select Edit the system environment variables in the search results.
Select Environment variables.
Note
The system variables should include the
ComSpecvariable. The expected value forComSpecisC:\WINDOWS\system32\cmd.exe.
Check whether more than one browser profile exists
To check if more than one profile exists, select the profile icon in the browser. A menu displaying the profiles should appear. The profile icon is usually located either on the top or right side of the browser window.
If more than one browser profile exists:
- Uninstall the Power Automate web extension from each existing browser profile.
- Close the browser and install the extension only in the browser profile that you use for the automation.
Check for errors in Windows Event Viewer
Follow these steps:
- Open Start, search for Event Viewer, and then select Event Viewer in the search results.
- In the left pane, expand Event Viewer (Local) > Windows Logs > Application.
- Locate the error entries that are related to Power Automate for desktop.
Disable other web extensions
Try disabling all other web extensions except the Power Automate extension to see if the problem continues.
Disable browser background settings
Some browser settings can interfere with the Power Automate extension. To resolve this problem, disable the following settings in your browser:
- Open Microsoft Edge or Google Chrome.
- Go to Settings > System and performance.
- Turn off the following settings:
- Continue running background extensions and apps when Microsoft Edge is closed (or Continue running background apps when Google Chrome is closed).
- Startup boost (Microsoft Edge only).
Check whether both MSI and MSIX installations exist
If both the MSI and Microsoft Store (MSIX) installations of Power Automate for desktop are present on the same machine, the web extension might fail to connect to the browser. For more information, see Web automation action fails when the machine runtime and Microsoft Store (MSIX) versions are different.
Third-party information disclaimer
The third-party products that this article discusses are manufactured by companies that are independent of Microsoft. Microsoft makes no warranty, implied or otherwise, about the performance or reliability of these products.