Skip to content

codex unusable due to continuous reconnection loop and stream disconnections #25103

Closed

Description

@GiovannyPonte

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

Codex 26.519.81530

What subscription do you have?

ChatGPT Pro

What platform is your computer?

Microsoft Windows 10 Pro Windows Version: 2009 OS Build: 10.0.26100.1 64-bit

What issue are you seeing?

Asunto: Codex unusable due to continuous reconnection loop and stream disconnections

Hello OpenAI Support,

I am experiencing a persistent issue with Codex that started on May 28, 2026 and is still occurring on May 29, 2026.

Environment:

  • ChatGPT Pro
  • Codex accessed through chatgpt.com
  • Windows 11
  • Google Chrome (also reproduced in other browser sessions)

Problem:
Every Codex task enters a reconnection loop and never completes. The interface repeatedly shows:

Reconnecting... 1/5
Reconnecting... 2/5
Reconnecting... 3/5
Reconnecting... 4/5
Reconnecting... 5/5

After several attempts, the following error appears:

"stream disconnected before completion: error sending request for url (https://chatgpt.com/backend-api/codex/responses)"

Impact:

  • Codex is effectively unusable.
  • Tasks fail before completion.
  • The problem has persisted for more than 24 hours.
  • Multiple retries produce the same result.

Troubleshooting already attempted:

  • Refreshing the page
  • Logging out and back in
  • Using different browser sessions
  • Verifying internet connectivity
  • Retrying multiple times over two consecutive days

Please confirm whether this is a known service issue affecting Codex and whether there is an estimated time for resolution.

I have attached a screenshot showing the error.

Thank you.

What steps can reproduce the bug?

  1. Launch Codex Desktop App version 26.519.81530.

  2. Sign in with a ChatGPT Pro account.

  3. Create a new conversation.

  4. Enter any prompt, including very simple prompts such as:

    • hello
    • create a file named test.txt
    • explain recursion
  5. Submit the prompt and wait for the response.

  6. Codex begins generating a response but repeatedly enters:

    Reconnecting... 1/5
    Reconnecting... 2/5
    Reconnecting... 3/5
    Reconnecting... 4/5
    Reconnecting... 5/5

  7. After several reconnection attempts, the request fails with:

    stream disconnected before completion: error sending request for url (https://chatgpt.com/backend-api/codex/responses)

Expected result:
Codex completes the response normally.

Actual result:
The response stream disconnects repeatedly and the task never completes.

Frequency:
100% reproducible since May 28, 2026.

Additional notes:

  • Occurs with both existing and newly created conversations.
  • Occurs with simple and complex prompts.
  • Internet connection is stable.
  • The issue has persisted for more than 24 hours.
  • Screenshots attached.

What is the expected behavior?

No response

Additional information

The issue appears specifically related to the Codex backend endpoint:
/backend-api/codex/responses

The behavior suggests that the response stream is being interrupted before completion, causing repeated reconnection attempts followed by failure.

Activity

  1. added
    app
    on May 29, 2026
  2. added
    bug
    connectivity
    on May 29, 2026
  3. etraut-openai commented on May 29, 2026

    @etraut-openai
    Contributor

    These types of connectivity problems are often caused by network instability or local VPN/proxy issues.

    You could try installing the Codex CLI and running codex doctor. This will run some diagnostics and give you a report.

  4. GiovannyPonte commented on May 29, 2026

    @GiovannyPonte
    Author
  5. GiovannyPonte commented on May 29, 2026

    @GiovannyPonte
    Author
  6. GiovannyPonte commented on May 29, 2026

    @GiovannyPonte
    Author
  7. GiovannyPonte commented on May 29, 2026

    @GiovannyPonte
    Author
  8. zhangtingyu11 commented on Jul 21, 2026

    @zhangtingyu11

    Same issue, the thread ID is 019f826c-46ee-7d82-af77-7b3178dcefed.

  9. 445021381ad999-max commented on Jul 21, 2026

    @445021381ad999-max

    I resolved a very similar Windows reconnection/stream-disconnection problem by fixing stale proxy environment variables.

    In my case, the Windows system proxy was working, so browser ChatGPT worked normally. However, the Codex/ChatGPT desktop process inherited old user environment variables:

    HTTP_PROXY=http://127.0.0.1:6850
    HTTPS_PROXY=http://127.0.0.1:6850
    

    Port 6850 was no longer listening. My actual proxy client was listening on 127.0.0.1:7892. The desktop app therefore kept failing with:

    stream disconnected before completion: error sending request for url (https://chatgpt.com/backend-api/codex/responses)
    

    It later also failed OAuth login with:

    token_exchange_failed: error sending request for url (https://auth.openai.com/oauth/token)
    

    Checks and fix

    Find the real proxy listening port:

    netstat -ano | findstr LISTENING

    Check inherited proxy variables:

    Get-ChildItem Env: | Where-Object Name -Match 'PROXY'
    [Environment]::GetEnvironmentVariable("HTTP_PROXY", "User")
    [Environment]::GetEnvironmentVariable("HTTPS_PROXY", "User")

    Then either update them to the proxy client's real port (replace 7892 with your own port):

    setx HTTP_PROXY "http://127.0.0.1:7892"
    setx HTTPS_PROXY "http://127.0.0.1:7892"

    or remove stale variables and rely on the Windows system proxy:

    [Environment]::SetEnvironmentVariable("HTTP_PROXY", $null, "User")
    [Environment]::SetEnvironmentVariable("HTTPS_PROXY", $null, "User")
    [Environment]::SetEnvironmentVariable("ALL_PROXY", $null, "User")

    Finally, fully terminate all ChatGPT.exe and codex.exe processes and restart the app. Existing processes keep the old environment values.

    After correcting the stale port and restarting every process, streaming and login both worked immediately. Reinstalling the app alone did not help because user environment variables persisted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    appbugconnectivity

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions