NextChat

Deploy NextChat (formerly ChatGPT-Next-Web) with BASE_URL and friends, or enter a custom endpoint in its settings

NextChat (formerly ChatGPT-Next-Web) is a lightweight open-source web chat app with a desktop build. These steps were checked against NextChat's README and source code on 2026-11-15 (latest release: v2.16.1, published 2025-07-29).

Get an API key#

Create one at qd.zsopc.com/dashboard/keys (sk-gpushare- plus 64 hex characters; you can re-reveal it on its detail page at any time).

docker run -d -p 3000:3000 \
  -e OPENAI_API_KEY=sk-gpushare-xxx \
  -e BASE_URL=https://qd.zsopc.com \
  -e CUSTOM_MODELS=-all,+claude-sonnet-4-6@OpenAI,+gpt-6.1-sol@OpenAI,+deepseek-v4.1-flash@OpenAI \
  -e CODE=your-access-password \
  yidadaa/chatgpt-next-web
  • No /v1 in BASE_URL: NextChat appends /v1/chat/completions itself, so https://qd.zsopc.com/v1 turns into /v1/v1/....
  • CUSTOM_MODELS: -all hides the built-in models, +model-id adds one, comma-separated. The @OpenAI suffix sends that model to the OpenAI-compatible address above.
  • CODE: the access password (several, comma-separated). Always set it on a public deployment, or anyone can spend your key.
  • To stop users entering their own keys in the page, add -e HIDE_USER_API_KEY=1.

To send Claude and Gemini over their native protocols, add the lines below and give those models the @Anthropic / @Google suffix (e.g. +claude-sonnet-4-6@Anthropic, +gemini-3.1-pro-low@Google):

  -e ANTHROPIC_URL=https://qd.zsopc.com \
  -e ANTHROPIC_API_KEY=sk-gpushare-xxx \
  -e GOOGLE_URL=https://qd.zsopc.com \
  -e GOOGLE_API_KEY=sk-gpushare-xxx \

Neither address takes a version either. @OpenAI alone also reaches Claude and Gemini models — the gateway translates the protocol for you, see the compatibility matrix.

Configure in the settings#

  1. Settings → turn on Custom Endpoint
  2. Set Model Provider to OpenAI
  3. OpenAI Endpoint: https://qd.zsopc.com (no /v1)
  4. OpenAI API Key: your sk-gpushare-...
  5. Custom Models: the model IDs you want, comma-separated, e.g. claude-sonnet-4-6,gpt-6.1-sol

This route suits the desktop app. In the web build, a custom endpoint makes the browser call the API directly, and this platform's API does not allow cross-origin calls from third-party web pages, so it fails. For the web build, use the deploy-time configuration above so NextChat's server forwards the requests.

Troubleshooting#

SymptomWhat to check
404An extra /v1 in the address: both BASE_URL and the endpoint field take just https://qd.zsopc.com
403 you are not allowed to use ... modelOnce CUSTOM_MODELS is set, only the listed models are allowed — add the model to it
401 invalid_api_keyWhether the key was copied in full (76 characters); re-reveal it on the key detail page
400 model_not_foundModel ID spelling — it must match Models exactly
402 quota_exceededBalance exhausted. Every key shares one account balance — top up on the Top up page
Network or CORS errors in the web buildSee the note under "Configure in the settings"

Full error reference: Error codes.

Other clients#