how can I achieve setting the http proxy with cursor cli, exporting the https_proxy and http_proxy variables doesn’t seem to help
Hey, there’s no official info about proxy support in the CLI, but you can try a workaround using the system proxy.
Try setting up the proxy in your OS settings (System Preferences > Network > Advanced > Proxies on macOS, or Settings > Network & Internet > Proxy on Windows). The CLI might pick up the system proxy automatically.
If that doesn’t help, please share:
- CLI version (run
agent --version) - OS and version
- What proxy you’re using (corporate or local, HTTP or SOCKS)
- The environment variables you’re exporting (paste the full command)
A similar question is here: Cursor CLI with proxy
It seems that it does’t work.
cli version: 2026.01.09-231024f
os: mac OS 15.6.1
http proxy
environment variables
export PYTHON_HOME=/Library/Frameworks/Python.framework/Versions/3.10
export ANDROID_HOME=~/Library/Android/sdk
export ANDROID_SDK=~/Library/Android/sdk
export NDK=/Users/a58/Library/Android/sdk/ndk/29.0.14206865
export ANDROID_NDK=/Users/a58/Library/Android/sdk/ndk/29.0.14206865
export TVM_NDK_CC=$NDK/toolchains/llvm/prebuilt/darwin-x86_64/bin/aarch64-linux-android33-clang
#export CMAKE=/Users/a58/Library/Android/sdk/cmake/4.1.2/bin/
export CMAKE=/Users/a58/Library/Android/sdk/cmake/3.22.1/bin/
export AAPT_TOOLS=/Users/a58/Library/Android/sdk/build-tools/29.0.2/
export PATH=${PATH}:/Users/a58/Library/Android/sdk/platform-tools/
export PATH=${PATH}:/opt/homebrew/bin/
export PATH=${PATH}:/Users/a58/Downloads/infer-osx-arm64-v1.2.0/bin/
export PATH=${PATH}:/Users/a58/.gradle/wrapper/dists/gradle-7.5-all/53f1ffk4w1cpu9gl7h9reqjeg/gradle-7.5/bin/i
export PATH=${PATH}:$PYTHON_HOME/bin/python3
export PATH=${PATH}:$AAPT_TOOLS
export PATH=${PATH}:$CMAKE
alias pip=$PYTHON_HOME/bin/pip3
export RUST=~/.cargo/bin
export PATH=${PATH}:$RUST
export TVM_SOURCE_DIR=/Users/a58/codes/github/mlc-llm/3rdparty/tvm
export http_proxy="http://127.0.0.1:7897"
export https_proxy="http://127.0.0.1:7897"
another question
why do I have some models that can use in cli
auto
composer-1
Grok
But I have more models in Cursor (that editor)
auto
composer-1
Grok
Sonnet4.5
GPT
....
I set the http proxy for the Cursor by user settings.
So why not support the http proxy for Cursor cli?
1 Like