DeepSeekDSH
Independent community guideNot affiliated with DeepSeek.Download versions and guide references

Deploy Open WebUI with DeepSeek API & Docker

Deploy Open WebUI in Docker and connect DeepSeek API or local Ollama models for self-hosted multi-user chat, document RAG, and web search.

On this page
Open WebUI parameters
  • OpenAI-compatible Endpoint: https://api.deepseek.com/v1 or https://api.deepseek.com
  • API key: Generated in your DeepSeek Platform console.
  • Default web interface: http://localhost:3000 or http://your-server-ip:3000
STEP 1

One-line Docker & Docker Compose setup

Launch Open WebUI using the official container image:

# Option A: Single command Docker run docker run -d -p 3000:8080 \ -e OPENAI_API_BASE_URL=https://api.deepseek.com/v1 \ -e OPENAI_API_KEY=sk-your_deepseek_api_key \ -v open-webui:/app/backend/data \ --name open-webui \ --restart always \ ghcr.io/open-webui/open-webui:main

Or use docker-compose.yml for persistent multi-container workflows:

version: '3.8' services: open-webui: image: ghcr.io/open-webui/open-webui:main container_name: open-webui ports: - "3000:8080" environment: - OPENAI_API_BASE_URL=https://api.deepseek.com/v1 - OPENAI_API_KEY=sk-your_deepseek_api_key volumes: - open-webui-data:/app/backend/data restart: always volumes: open-webui-data:
STEP 2

Web interface initialization and model activation

  1. Open http://localhost:3000 in your browser and create your administrator account (stored locally inside your Docker volume—the first account created automatically becomes the local admin).
  2. Navigate to Admin Panel → Settings → Connections in the bottom-left menu.
  3. Under OpenAI API, verify the Base URL is https://api.deepseek.com/v1 and paste your API key.
  4. Click the refresh icon to verify that deepseek-chat and deepseek-reasoner are populated and enabled.
Connecting local Ollama from Docker: Inside a Docker container, localhost refers to the container itself. To reach Ollama running on your host machine (`11434`), point the Ollama URL to http://host.docker.internal:11434 (on Linux, add --add-host=host.docker.internal:host-gateway to docker run).
STEP 3

Build document RAG knowledge bases

Open WebUI supports uploading PDF, Markdown, TXT, and DOCX files for private retrieval:

  1. Click Workspace → Knowledge in the sidebar and create a new knowledge collection.
  2. Upload your project manuals or internal wikis; the engine chunks and indexes the content automatically.
  3. In any chat conversation, type #collection-name or attach the knowledge base to query your documents directly with DeepSeek.
Embedding model note: Official api.deepseek.com does not provide a /v1/embeddings endpoint. Keep Admin Settings → Documents → Embedding Model Engine set to Default (local SentenceTransformers) or an Ollama/external embedding provider.

Troubleshooting

Empty model catalog

Ensure OPENAI_API_BASE_URL includes the /v1 suffix and that the server has outbound internet access to api.deepseek.com.

R1 reasoning chain rendering issues

Recent releases of Open WebUI support foldable reasoning_content blocks out of the box. Ensure you are running the latest open-webui:main Docker tag.

References