How to Deploy DeepSeek R1 Locally: A Step‑by‑Step AI Model Guide

This article walks you through everything you need to know about DeepSeek R1—including its different model sizes, hardware requirements, installation tools like Ollama, LM Studio and Docker, and how to set up a visual interface with Open‑WebUI or Dify—for offline, private, and cost‑effective AI inference.

MaGe Linux Operations
MaGe Linux Operations
MaGe Linux Operations
How to Deploy DeepSeek R1 Locally: A Step‑by‑Step AI Model Guide

What is DeepSeek R1

DeepSeek‑R1, released on 2025‑01‑20, is the first inference model from DeepSeek AI, positioned as a competitor to OpenAI’s o1. It excels at complex reasoning tasks such as mathematics, code generation, and logical inference. The model is offered in a full‑size version (671 B parameters) and several distilled versions ranging from 1.5 B to 70 B parameters.

The full‑size version delivers the strongest performance but requires extremely high‑end hardware, while the distilled versions are designed for typical consumer hardware with lower memory and GPU demands.

Model Versions and Hardware Requirements

Full‑size (671 B) : Requires at least 350 GB of VRAM/ RAM; suitable for professional server deployments.

Distilled versions (1.5 B, 7 B, 8 B, 14 B, 32 B, 70 B): Built by fine‑tuning open‑source bases such as QWEN or LLaMA; hardware needs range from modest (1.5 B) to high‑end (70 B).

Typical hardware recommendations:

Windows – Minimum : NVIDIA GTX 1650 4 GB or AMD RX 5500 4 GB, 16 GB RAM, 50 GB storage.

Windows – Recommended : NVIDIA RTX 3060 12 GB or AMD RX 6700 10 GB, 32 GB RAM, 100 GB NVMe SSD.

Linux – High‑Performance : NVIDIA A100 40 GB or AMD MI250X 128 GB, 128 GB RAM, 200 GB NVMe SSD.

Mac – High‑Performance : M2 Max/Ultra Mac Studio with 64 GB RAM.

Model‑specific resource estimates (e.g., deepseek-r1:7b needs ~5 GB VRAM, deepseek-r1:32b ~22 GB VRAM) are provided to help you match a model to your machine.

Local Installation Steps

We used an M2/M3/M4 MacBook Pro (16 GB RAM) with the deepseek-r1:8b model for demonstration.

Benefits of local deployment include data privacy, offline usage, zero API cost, low latency, and full customisation.

Deployment Tools

Ollama : A cross‑platform LLM manager that runs models locally via CLI or Docker. Example command: ollama run deepseek-r1:7b.

LM Studio : Desktop UI for downloading and running various LLMs, supporting CPU + GPU mixed inference.

Docker : Suitable for advanced users; example container launch:

docker run -d --gpus=all -p 11434:11434 --name ollama ollama/ollama

.

We chose Ollama for the main deployment because it offers straightforward local model management.

Installing Ollama

Download the appropriate installer from ollama.com , run the installer, and verify the installation in the terminal.

After installation, pull the desired DeepSeek model with the provided command (e.g., ollama run deepseek-r1:8b) and confirm it runs successfully.

Setting Up a Visual Interface

Two popular self‑hosted UI options are Open‑WebUI and Dify.

Open‑WebUI

Open‑WebUI provides a web UI for interacting with local LLMs. Install it via Docker:

docker run -d -p 3000:8080 --add-host=host.docker.internal:host-gateway -v open-webui:/app/backend/data --name open-webui --restart always ghcr.io/open-webui/open-webui:main

Access the UI at http://localhost:3000, create an account, and select the Ollama backend.

Dify

Dify is an LLM application platform that supports API integration, RAG, and AI agents. After launching Dify (Docker or native), configure the model provider URL as http://host.docker.internal:11434 to connect to the locally running Ollama service.

Both interfaces allow you to test the deepseek-r1:8b model and observe its responses.

Usage Tips and Observations

The distilled models work well for privacy‑preserving, offline tasks, though code generation may occasionally be imperfect. For the highest performance, the full‑size model is recommended, but it requires enterprise‑grade hardware. If such hardware is unavailable, using DeepSeek’s hosted API is a cost‑effective alternative.

Overall, the guide demonstrates a complete workflow from model selection, hardware sizing, installation, to UI integration, enabling you to run DeepSeek R1 locally for a variety of AI applications.

Original Source

Signed-in readers can open the original source through BestHub's protected redirect.

Sign in to view source
Republication Notice

This article has been distilled and summarized from source material, then republished for learning and reference. If you believe it infringes your rights, please contactadmin@besthub.devand we will review it promptly.

DockerAILLMDeepSeeklocal deployment
MaGe Linux Operations
Written by

MaGe Linux Operations

Founded in 2009, MaGe Education is a top Chinese high‑end IT training brand. Its graduates earn 12K+ RMB salaries, and the school has trained tens of thousands of students. It offers high‑pay courses in Linux cloud operations, Python full‑stack, automation, data analysis, AI, and Go high‑concurrency architecture. Thanks to quality courses and a solid reputation, it has talent partnerships with numerous internet firms.

0 followers
Reader feedback

How this landed with the community

Sign in to like

Rate this article

Was this worth your time?

Sign in to rate
Discussion

0 Comments

Thoughtful readers leave field notes, pushback, and hard-won operational detail here.