You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Specifically, the model_providers.openai provider appears to be immutable or internally defined in a way that prevents overriding transport capabilities. As a result, Codex CLI continues attempting to establish WebSocket connections even when explicitly disabled in configuration.
Observed Behavior
Codex CLI attempts WebSocket transport by default.
Even after setting supports_websockets = false, WebSocket connections are still attempted.
There appears to be no reliable way to force HTTPS-only transport via configuration.
Expected Behavior
One of the following should be possible:
supports_websockets = false should correctly disable WebSocket usage for model_providers.openai, or
A CLI flag should exist to explicitly force HTTPS transport as the preferred (or exclusive) transport method.
Can you describe the behavior that you're seeing that's causing you to want to disable websocket transport? The feature flag was in place for development, but we typically remove feature flags once features are rolled out and stable.
Can you describe the behavior that you're seeing that's causing you to want to disable websocket transport? The feature flag was in place for development, but we typically remove feature flags once features are rolled out and stable.
Hi, Currently, I am running codex in an internal network environment (at a research institute's computing node), so I used a proxy. It worked normally before version v0.106.0, but after upgrading to that version, it started to encounter
{"type":"thread.started","thread_id":"xxx"}
{"type":"item.completed","item":{"id":"item_0","type":"error","message":"Under-development features enabled: realtime_conversation, responses_websockets_v2, voice_transcription. Under-development features are incomplete and may behave unpredictably. To suppress this warning, set `suppress_unstable_features_warning = true` in /home/xxx/.codex/config.toml."}}
{"type":"turn.started"}
{"type":"error","message":"Reconnecting... 2/5 (stream disconnected before completion: failed to send websocket request: Connection closed normally)"}
{"type":"error","message":"Reconnecting... 3/5 (stream disconnected before completion: failed to send websocket request: Connection closed normally)"}
{"type":"error","message":"Reconnecting... 4/5 (stream disconnected before completion: failed to send websocket request: Connection closed normally)"}
{"type":"error","message":"Reconnecting... 5/5 (stream disconnected before completion: failed to send websocket request: Connection closed normally)"}
{"type":"item.completed","item":{"id":"item_1","type":"error","message":"Falling back from WebSockets to HTTPS transport. stream disconnected before completion: failed to send websocket request: Connection closed normally"}}
I am also running into this. Afaik this was the timeline of events for me
I tried to turn on the responses_websockets_v2 feature via ~/.codex/config.toml. This did not work, both on the Codex app + CLI (both at the latest versions as of today) I saw
Reconnecting 1..2..3..4..5
stream disconnected before completion: failed to send websocket request: Connection closed normally
I then went back to the config file and commented out the responses_websockets_v2 feature.
However, this was never turned off, even today after a hard close + refersh of the apps, terminal and system it still seems to be using the websocket setting.
Can you describe the behavior that you're seeing that's causing you to want to disable websocket transport? The feature flag was in place for development, but we typically remove feature flags once features are rolled out and stable.
In 100% cases I met websocket error and fallback to https (with about 1min wasted). I would like to disable websocket for convenience.
Activity
github-actions commentedon Feb 28, 2026
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
etraut-openai commentedon Feb 28, 2026
Can you describe the behavior that you're seeing that's causing you to want to disable websocket transport? The feature flag was in place for development, but we typically remove feature flags once features are rolled out and stable.
hanx-hep commentedon Feb 28, 2026
Hi, Currently, I am running codex in an internal network environment (at a research institute's computing node), so I used a proxy. It worked normally before version v0.106.0, but after upgrading to that version, it started to encounter
This is similar to #13041
I'm not sure if the issue is with the proxy I'm using (I tried both socks and http), or a bug in this version itself, so I want to disable it first.
hanx-hep commentedon Feb 28, 2026
Hi, I just tried again without using a proxy, on a completely new virtual machine, and the same error still occurs.
Thread ID 019ca306-15e2-7dc0-8951-198b7e6d1616
kali113 commentedon Feb 28, 2026
@hanx-hep if you want, you can close this one and talk in #13041
hanx-hep commentedon Feb 28, 2026
@kali113 My issue is a bit different; I hope to provide an option to modify whether to use WS. Therefore, this might still be kept?
kali113 commentedon Feb 28, 2026
@hanx-hep can you do codex features list in cli
user753 commentedon Feb 28, 2026
I have the same problem and also would like to disable websocket
AdiRishi commentedon Feb 28, 2026
I am also running into this. Afaik this was the timeline of events for me
I tried to turn on the
responses_websockets_v2feature via~/.codex/config.toml. This did not work, both on the Codex app + CLI (both at the latest versions as of today) I sawI then went back to the config file and commented out the responses_websockets_v2 feature.
However, this was never turned off, even today after a hard close + refersh of the apps, terminal and system it still seems to be using the websocket setting.
Weaverzhu commentedon Feb 28, 2026
In 100% cases I met websocket error and fallback to https (with about 1min wasted). I would like to disable websocket for convenience.
kali113 commentedon Feb 28, 2026
@Weaverzhu go into #13041
takina0802 commentedon Mar 18, 2026
Hi, I found a solution in #13041: #13041 (comment).
Add the following configuration in
~/.codex/config.toml:hanx-hep commentedon Mar 18, 2026
Hello, indeed this method can be used, but this provider may not fully inherit all the features of the official codex provider.
However, it seems that the wss bug in version v0.106.0 has been fixed in subsequent updates, so at least I don't need this requirement anymore.
feat(m3): USE_DIRECT_PYTHON mode + tail-scan extractor + bind-mount logs
fix(web): Codex 生成配置固定 supports_websockets = false,缓解 WS 405 重连风暴
Somebi commentedon Aug 5, 2026
So how this was eventually solved?
docs(codex): record the substitution and the unpinned CLI it depends on
fix(codex): a brokered turn stops paying a 300s websocket timeout
docs(codex): record the substitution and the unpinned CLI it depends on
fix(codex): a brokered turn stops paying a 300s websocket timeout
docs(codex): record the substitution and the unpinned CLI it depends on
fix(codex): a brokered turn stops paying a 300s websocket timeout
docs(codex): record the substitution and the unpinned CLI it depends on
fix(codex): a brokered turn stops paying a 300s websocket timeout (#1682