cheapaimodel

Open WebUI

Chat with cheapaimodel models in Open WebUI through an OpenAI API connection.

Copy

Open WebUI reaches OpenAI-compatible services through OpenAI API connections, which an admin adds under Settings → Admin → Connections. Once the connection is saved, its models show up in every user's model selector.

Open WebUI settingValue
Base URLURLhttps://api.cheapaimodel.ai/v1
API keyAPI Key (with Auth on Bearer)Your key from the console's API Keys page
Model IDModel selector, or Advanced → Model IDsdeepseek-v4-1-flash, or any ID from the catalog

Set it up

Add the connection

  1. Signed in as an admin, open Settings → Admin → Connections.
  2. Next to Manage OpenAI API Connections, select Add Connection (the + button).
  3. Set URL to https://api.cheapaimodel.ai/v1.
  4. Leave Auth on Bearer and paste your cheapaimodel key into API Key.
  5. Leave API Type on Chat Completions.
  6. Select Verify Connection, then Save.

Pick a model

Open WebUI reads the model list from /v1/models, which returns the models your key may use. Choose deepseek-v4-1-flash in the model selector and start a chat.

To offer only some models, add their IDs under Advanced → Model IDs; Open WebUI then lists exactly those and stops fetching the list. If another connection serves the same IDs, set a Prefix ID such as cheapaimodel: the model appears as cheapaimodel.deepseek-v4-1-flash, and Open WebUI strips the prefix before sending the request.

Environment variables

On a new install you can create the same connection at startup. Add the two variables to the command or Compose file you start Open WebUI with:

Terminal
docker run -d -p 3000:8080 \
  -v open-webui:/app/backend/data \
  -e OPENAI_API_BASE_URL="https://api.cheapaimodel.ai/v1" \
  -e OPENAI_API_KEY="$CHEAPAIMODEL_API_KEY" \
  --name open-webui --restart always \
  ghcr.io/open-webui/open-webui:main

Open WebUI reads these only on its first start and then keeps the values in its database. Change the connection later in Settings → Admin → Connections.

Documents and knowledge

cheapaimodel has no embeddings models yet. Leave the embedding engine under Settings → Admin → Documents on Open WebUI's built-in model or another provider; don't point it at cheapaimodel. The :slim image has no built-in embedding model, so RAG there needs another provider's embeddings.

Common mistakes

  • Verify Connection fails with 404 and fault filter abort, and no models appear. URL is missing /v1. Set https://api.cheapaimodel.ai/v1.
  • Every message fails with 404 and Invalid URL (POST /v1/chat/completions/chat/completions). URL includes the endpoint path. Open WebUI adds the path itself; set https://api.cheapaimodel.ai/v1.
  • 401. The key is wrong, expired or out of budget, or Auth is not Bearer. Check the key in the console.
  • 503 with model_not_found. An ID typed into Model IDs doesn't match the catalog. Fix the spelling, or clear the list to fetch it from /v1/models.
  • Changed environment variables have no effect. They only apply on the first start. Edit the connection in Settings → Admin → Connections.