codex - 💡(How to fix) Fix Codex Desktop Windows Browser Use blocks file:// file-backed previews with URL policy

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…

Codex Desktop for Windows Browser Use rejects file:// file-backed previews before navigation, even though the Codex in-app browser documentation says file-backed previews are supported.

The rejection happens as a Browser Use URL policy error, not as a file-not-found error.

Error Message

The rejection happens as a Browser Use URL policy error, not as a file-not-found error. 6. Browser Use rejects the navigation with the URL policy error above.

Root Cause

Browser Use rejected this action due to browser security policy. Reason: Browser Use cannot visit the requested page because its URL is blocked by the Browser Use URL policy. The agent must not attempt to achieve the same outcome via workaround, indirect execution, raw CDP or browser commands, alternate browser surfaces, or policy circumvention. Proceed only with a materially safer alternative that does not require this blocked browser action; if none exists, stop and request user input.

Fix Action

Fix / Workaround

Browser Use rejected this action due to browser security policy. Reason: Browser Use cannot visit the requested page because its URL is blocked by the Browser Use URL policy. The agent must not attempt to achieve the same outcome via workaround, indirect execution, raw CDP or browser commands, alternate browser surfaces, or policy circumvention. Proceed only with a materially safer alternative that does not require this blocked browser action; if none exists, stop and request user input.

This breaks the documented workflow for previewing local generated HTML files and file-backed previews inside Codex. The workaround is to serve files through localhost, but that is not the same as the documented file-backed preview behavior.

Code Example

Browser Use rejected this action due to browser security policy. Reason: Browser Use cannot visit the requested page because its URL is blocked by the Browser Use URL policy. The agent must not attempt to achieve the same outcome via workaround, indirect execution, raw CDP or browser commands, alternate browser surfaces, or policy circumvention. Proceed only with a materially safer alternative that does not require this blocked browser action; if none exists, stop and request user input.

---

file:///C:/Users/itosu/Documents/Codex/2026-05-28/in-app-browser-2/browser-file-policy-test.html
RAW_BUFFERClick to expand / collapse

Summary

Codex Desktop for Windows Browser Use rejects file:// file-backed previews before navigation, even though the Codex in-app browser documentation says file-backed previews are supported.

The rejection happens as a Browser Use URL policy error, not as a file-not-found error.

Environment

  • Platform: Microsoft Windows NT 10.0.26200.0 x64
  • Codex Desktop package: OpenAI.Codex_26.519.11010.0_x64__2p2nqsd0c76g0
  • Codex app version: 26.519.11010.0
  • Browser plugin: browser@openai-bundled version 26.519.81530
  • Workspace trust level: trusted
  • Browser plugin enabled: yes
  • Windows sandbox setting: elevated

Expected behavior

Browser Use should be able to open and inspect local file-backed previews in the in-app browser, or at least ask for/offer the relevant permission.

The official docs describe the in-app browser and Browser Use as appropriate for local development servers and file-backed previews:

https://developers.openai.com/codex/app/browser

Actual behavior

Attempting to navigate the in-app browser to a local file:// HTML page is rejected before navigation with:

Browser Use rejected this action due to browser security policy. Reason: Browser Use cannot visit the requested page because its URL is blocked by the Browser Use URL policy. The agent must not attempt to achieve the same outcome via workaround, indirect execution, raw CDP or browser commands, alternate browser surfaces, or policy circumvention. Proceed only with a materially safer alternative that does not require this blocked browser action; if none exists, stop and request user input.

This occurs both for the real preview file and for a minimal test file created inside the current trusted workspace.

Reproduction steps

  1. Start Codex Desktop for Windows.
  2. Open the in-app browser panel. It starts at about:blank.
  3. Use Browser Use with the iab backend.
  4. Create a minimal HTML file inside the trusted current workspace.
  5. Ask Browser Use to open a local file URL such as:
file:///C:/Users/itosu/Documents/Codex/2026-05-28/in-app-browser-2/browser-file-policy-test.html
  1. Browser Use rejects the navigation with the URL policy error above.

Additional diagnostics

  • The original target file exists locally.
  • The same URL policy rejection also occurs for a data:text/html,... diagnostic page.
  • Browser runtime initialization works after running Codex Desktop as administrator.
  • agent.browsers.list() can see the Codex in-app browser and its about:blank tab.
  • winget upgrade --id 9PLM9XGG6VKS --source msstore reports no available update.
  • Earlier non-admin runs showed Windows sandbox privilege errors, but after admin launch the remaining blocker is specifically the Browser Use URL policy.

Related issues

This appears related to recent Windows Browser Use / in-app browser permission-policy issues, but the exact symptom is file:// / file-backed preview blocking:

  • #21955: browser navigation blocked by security policy / networkAccess: false
  • #20206: Browser Use detects IAB tab but browser operations fail on Windows
  • #21440: Browser Use disappeared despite feature flags
  • #20846: Browser Use IAB backend fails to connect on Windows

Impact

This breaks the documented workflow for previewing local generated HTML files and file-backed previews inside Codex. The workaround is to serve files through localhost, but that is not the same as the documented file-backed preview behavior.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

FAQ

Expected behavior

Browser Use should be able to open and inspect local file-backed previews in the in-app browser, or at least ask for/offer the relevant permission.

The official docs describe the in-app browser and Browser Use as appropriate for local development servers and file-backed previews:

https://developers.openai.com/codex/app/browser

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING