Unable to disable WebSocket transport
Resolved 💬 13 comments Opened Feb 28, 2026 by hanx-hep Closed Mar 18, 2026
💡 Likely answer: A maintainer (github-actions[bot], contributor)
responded on this thread — see the highlighted reply below.
---
Description
I am encountering an issue where configuring:
supports_websockets = false
in config.toml does not take effect.
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 = falseshould correctly disable WebSocket usage formodel_providers.openai, or- A CLI flag should exist to explicitly force HTTPS transport as the preferred (or exclusive) transport method.
For example:
codex --transport https
or
codex --prefer-https
---
Environment
- OS: Linux
- Codex CLI version: 0.106.0
- Network: Proxy environment (HTTP / SOCKS / Reality-based proxy)
- Issue reproducible: Yes
13 Comments
Potential duplicates detected. Please review them and close your issue if it is a duplicate.
Powered by Codex Action
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
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.
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
@hanx-hep if you want, you can close this one and talk in https://github.com/openai/codex/issues/13041
@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?
@hanx-hep can you do codex features list in cli
I have the same problem and also would like to disable websocket
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.
In 100% cases I met websocket error and fallback to https (with about 1min wasted). I would like to disable websocket for convenience.
@Weaverzhu go into #13041
Hi, I found a solution in #13041: https://github.com/openai/codex/issues/13041#issuecomment-3981110494.
Add the following configuration in
~/.codex/config.toml: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.