openai / openai/codex

[Windows] Chrome plugin installed and extension detected, but Native Messaging Host is never installed

Open
#43,849 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

app browser bug skills windows-os
Dominant language
Rust
Stars
125k
Forks
19.4k
PR merge metrics
PR metrics pending

Description

What version of the Codex App are you using (From “About Codex” dialog)?

26.901.6511.0

What subscription do you have?

ChatGPT Plus

What platform is your computer?

Windows 11 x64

What issue are you seeing?
Summary

On Windows, the Codex Chrome plugin is installed and enabled, and the official Chrome extension is correctly detected in the selected Chrome profile.

However, the required Native Messaging Host registration is missing.

As a result, Codex cannot communicate with existing Chrome tabs and reports that the Chrome/browser connection bridge is unavailable.

The native host executable itself exists inside the bundled Chrome plugin, but both the Native Messaging Host manifest and the corresponding Windows registry entry are missing.

Following the documented recovery procedure by removing and reinstalling chrome@openai-bundled through the official Codex plugin CLI does not restore the Native Messaging Host registration.


Environment

OS

Windows 11 x64

Codex Windows app package

OpenAI.Codex_26.901.6511.0_x64__2p2nqsd0c76g0

Primary runtime plugins

26.905.11957

Bundled plugins

browser@openai-bundled
installed, enabled
version: 26.623.141536

chrome@openai-bundled
installed, enabled
version: 26.623.141536

computer-use@openai-bundled
installed, enabled
version: 26.623.141536

Google Chrome

C:\Program Files\Google\Chrome\Application\chrome.exe

Selected Chrome profile

Default

Chrome extension ID

hehggadaopoacecdllhhajmbjkdcmajg

Chrome extension diagnostics

The bundled Chrome diagnostics confirm that Chrome is running successfully.

chrome-is-running.js succeeds with:

ExitCode: 0

check-extension-installed.js also succeeds.

The extension is reported as:

installed: true
registered: true
enabled: true
selected: true

with:

ExitCode: 0

The official Chrome extension is therefore installed and enabled in the selected Chrome profile.


Native Messaging Host diagnostics

Using the diagnostic script bundled with the installed chrome@openai-bundled plugin:

node scripts/check-native-host-manifest.js --json

returns:

{
  "manifestPath": "C:\\Users\\<USER>\\AppData\\Local\\OpenAI\\extension\\com.openai.codexextension.json",
  "registryKey": "HKCU\\Software\\Google\\Chrome\\NativeMessagingHosts\\com.openai.codexextension",
  "registryManifestPath": null,
  "expectedHostName": "com.openai.codexextension",
  "expectedExtensionId": "hehggadaopoacecdllhhajmbjkdcmajg",
  "expectedOrigin": "chrome-extension://hehggadaopoacecdllhhajmbjkdcmajg/",
  "exists": false,
  "correct": false,
  "problem": "Windows native host registry key does not exist: HKCU\\Software\\Google\\Chrome\\NativeMessagingHosts\\com.openai.codexextension; Native host manifest does not exist: C:\\Users\\<USER>\\AppData\\Local\\OpenAI\\extension\\com.openai.codexextension.json"
}

The diagnostic exits with:

ExitCode: 1

Direct Windows checks confirm that this is not merely a diagnostic/parser issue.

Registry check
reg.exe query "HKCU\Software\Google\Chrome\NativeMessagingHosts\com.openai.codexextension" /ve

Result:

ERROR: The system was unable to find the specified registry key or value.
Manifest check

Expected manifest:

C:\Users\<USER>\AppData\Local\OpenAI\extension\com.openai.codexextension.json

Result:

Exists = False

Native host executable is present

The actual native host executable exists inside the bundled Chrome plugin:

...\openai-bundled\plugins\chrome\extension-host\windows\x64\extension-host.exe

Therefore, the native host executable itself is present, while the manifest/registry registration required for Chrome Native Messaging is missing.


Reinstalling the bundled Chrome plugin does not restore the registration

I completely closed the Codex desktop app and used the official Codex plugin CLI.

First:

codex.cmd plugin remove chrome@openai-bundled --json

Result:

{
  "pluginId": "chrome@openai-bundled",
  "name": "chrome",
  "marketplaceName": "openai-bundled"
}

Then:

codex.cmd plugin add chrome@openai-bundled --json

Result:

{
  "pluginId": "chrome@openai-bundled",
  "name": "chrome",
  "marketplaceName": "openai-bundled",
  "version": "26.623.141536",
  "installedPath": "C:\\Users\\<USER>\\.codex\\plugins\\cache\\openai-bundled\\chrome\\26.623.141536",
  "authPolicy": "ON_INSTALL"
}

The plugin is subsequently reported as:

chrome@openai-bundled
installed, enabled
26.623.141536

However, after reinstalling it:

  • The Native Messaging registry key is still missing.
  • com.openai.codexextension.json is still missing.
  • check-native-host-manifest.js --json still returns ExitCode 1.

Opening the selected Chrome profile also does not fix it

The bundled diagnostic command:

open-chrome-window.js --browser chrome --dry-run --json

correctly identifies the installed Chrome browser and selected profile:

{
  "browserFamily": "chrome",
  "browserName": "Google Chrome",
  "platform": "win32",
  "dryRun": true,
  "profileDirectory": "Default",
  "command": "cmd.exe",
  "args": [
    "/d",
    "/s",
    "/c",
    "start",
    "\"\"",
    "C:\\Program Files\\Google\\Chrome\\Application\\chrome.exe",
    "--profile-directory=Default",
    "--new-window",
    "about:blank"
  ]
}

I then ran the corresponding non-dry-run command, waited, and retried the Chrome browser connection.

The connection still failed.

Codex reports messages equivalent to:

Unable to read the current Chrome tabs because the browser connection service/bridge is unavailable.

Steps to reproduce
  1. Launch the Codex desktop app on Windows 11.

  2. Install and enable the official Codex/ChatGPT Chrome extension in Google Chrome.

  3. Verify that Chrome is running and that the extension is correctly detected.

    check-extension-installed.js reports that the extension is installed, registered, enabled, and selected, with ExitCode 0.

  4. Run the bundled Native Messaging Host diagnostic:

    node scripts/check-native-host-manifest.js --json
    
  5. The diagnostic returns ExitCode 1 and reports that both of the following are missing:

    C:\Users\<USER>\AppData\Local\OpenAI\extension\com.openai.codexextension.json
    
    HKCU\Software\Google\Chrome\NativeMessagingHosts\com.openai.codexextension
    
  6. Verify that the native host executable itself exists:

    ...\openai-bundled\plugins\chrome\extension-host\windows\x64\extension-host.exe
    
  7. Completely close the Codex desktop app.

  8. Remove and reinstall the bundled Chrome plugin:

    codex.cmd plugin remove chrome@openai-bundled --json
    codex.cmd plugin add chrome@openai-bundled --json
    
  9. Verify that chrome@openai-bundled is installed and enabled.

  10. Check the Native Messaging Host again.

    The manifest file and registry key are still not created, and check-native-host-manifest.js --json still returns ExitCode 1.

  11. Open the Chrome window/profile selected by the bundled diagnostic and retry a Chrome-backed Codex task, such as asking Codex to list the currently open Chrome tabs.

  12. Codex still cannot communicate with Chrome and reports that the browser connection service/bridge is unavailable.


Bundled troubleshooting guidance

The Chrome plugin's own docs/chrome-troubleshooting.md states:

"Do not install or repair the native host yourself. If native host setup appears broken, tell the user to reinstall the Chrome plugin from the Codex plugin UI."

It also states:

"Never import or run scripts/installManifest.mjs yourself."

Therefore, I did NOT manually run installManifest.mjs, manually create the Native Messaging Host manifest, or manually create the NativeMessagingHosts registry key.

Instead, I followed the documented recovery direction by removing and reinstalling the Chrome plugin through the official Codex plugin CLI.

This did not restore the Native Messaging Host registration.


Expected behavior

Following the documented recovery procedure (reinstalling the Chrome plugin) should restore the required Native Messaging Host registration, or otherwise trigger the supported setup flow that restores it.

After successful Chrome integration setup, the required Native Messaging Host manifest and Windows registration should be present and valid, and Codex should be able to communicate with the installed Chrome extension and access the selected Chrome profile.


Actual behavior

The Chrome extension and bundled Chrome plugin are both installed and detected successfully.

The native extension-host.exe executable is also present.

However, the Native Messaging Host manifest and corresponding Windows registry registration are missing and are not restored after reinstalling the bundled Chrome plugin.

Consequently, Codex cannot establish the Chrome extension/native-host bridge.


Additional observation

The bundled marketplace is resolved from:

C:\Users\<USER>\.codex\.tmp\bundled-marketplaces\openai-bundled

The bundled browser/chrome/computer-use plugins are reported as:

26.623.141536

while the Windows Codex app package is:

26.901.6511.0

and the primary-runtime plugins are:

26.905.11957

I do not know whether these independent version numbers are expected, so I am including them only as diagnostic information rather than assuming that the version difference is the cause.


Request

Could you please investigate why the Windows Chrome integration/native-host setup path does not create or restore the com.openai.codexextension Native Messaging Host registration in this configuration?

It would also be useful to clarify the supported recovery procedure when the bundled troubleshooting documentation says to reinstall the Chrome plugin from the Codex plugin UI, but the current Codex UI does not expose a reinstall action for the bundled Chrome plugin.

What steps can reproduce the bug?
  1. Launch the Codex desktop app on Windows 11.

  2. Install and enable the official Codex Chrome extension in Google Chrome.

  3. Verify that Chrome is running and that the extension is correctly detected by running the bundled diagnostics:

    node scripts/chrome-is-running.js --check
    node scripts/check-extension-installed.js --json
    

    chrome-is-running.js exits with code 0.

    check-extension-installed.js reports that the extension is installed, registered, enabled, and selected, and also exits with code 0.

  4. Run the bundled Native Messaging Host diagnostic:

    node scripts/check-native-host-manifest.js --json
    
  5. The diagnostic exits with code 1 and reports that both of the following are missing:

    C:\Users\<USER>\AppData\Local\OpenAI\extension\com.openai.codexextension.json
    
    HKCU\Software\Google\Chrome\NativeMessagingHosts\com.openai.codexextension
    
  6. Verify that the native host executable itself exists:

    ...\openai-bundled\plugins\chrome\extension-host\windows\x64\extension-host.exe
    
  7. Completely close the Codex desktop app.

  8. Remove and reinstall the official bundled Chrome plugin using:

    codex.cmd plugin remove chrome@openai-bundled --json
    codex.cmd plugin add chrome@openai-bundled --json
    
  9. Verify that chrome@openai-bundled is installed and enabled.

  10. Run the Native Messaging Host diagnostic again:

    node scripts/check-native-host-manifest.js --json
    

    The manifest file and registry key are still not created, and the diagnostic still exits with code 1.

  11. Open the selected Chrome profile using the bundled helper:

    node scripts/open-chrome-window.js
    

    Wait a few seconds, then retry a Chrome-backed Codex task, such as asking Codex to list the currently open Chrome tabs.

  12. Codex still cannot communicate with Chrome and reports that the browser connection service/bridge is unavailable.

Note

I did not manually run scripts/installManifest.mjs, manually create the Native Messaging Host manifest, or manually create the Windows registry entry because the bundled Codex troubleshooting documentation explicitly instructs users not to install or repair the native host manually.

What is the expected behavior?

Reinstalling chrome@openai-bundled should install and register the required Windows Native Messaging Host, creating:

C:\Users\<USER>\AppData\Local\OpenAI\extension\com.openai.codexextension.json

and:

HKCU\Software\Google\Chrome\NativeMessagingHosts\com.openai.codexextension

Codex should then be able to communicate with the installed Chrome extension and access the selected Chrome profile.

Additional information

No response

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The relevant entry points mentioned are scripts/chrome-is-running.js, scripts/check-extension-installed.js, scripts/check-native-host-manifest.js, open-chrome-window.js, and docs/chrome-troubleshooting.md in the bundled Chrome plugin. Start by tracing the supported plugin reinstall/setup path on Windows; done means reinstalling the plugin creates a valid com.openai.codexextension.json and registry entry and the native-host diagnostic passes.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
desktop, devtools
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Clearly specified
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.