DeepSeek is a powerful AI model that has garnered significant attention. While you can interact with it via its app or website, you can also deploy it locally on your Windows computer. This offers advantages like enhanced privacy and faster response times. By using a tool like cpolar, you can even access your locally hosted DeepSeek instance remotely through a web interface, giving you the convenience of a cloud-based AI with the benefits of local processing.
This article will guide you through the process of setting up DeepSeek R1 on your Windows machine and enabling remote access using a web interface.
Running AI models locally offers several key advantages:
Here's how to deploy DeepSeek R1 locally:
Ollama is an open-source tool designed to run various AI models.
ollama
and press Enter. If Ollama is installed correctly, you should see relevant information displayed.ollama run deepseek-r1:1.5b
While interacting with AI through the command line is functional, a GUI offers a more user-friendly experience. Open WebUI is a web interface specifically designed for Ollama. We will install Open WebUI via Docker.
If you don't have Docker installed, follow these steps:
Download Docker Desktop for Windows from the Docker website.
Run the installer.
Enable "Windows Subsystem for Linux" and "Virtual Machine Platform" via the Windows Features settings. You can find these by searching for "Turn Windows features on or off" in the start menu.
Open cmd with administrator privileges and run:
wsl --set-default-version 2
wsl --update --web-download
Restart your computer.
Launch Docker Desktop. Accept the terms and conditions, if prompted.
Verify Docker is running by checking for a green "running" status in the bottom-left corner of the Docker Desktop window.
You can also verify the installation by opening PowerShell and running docker
.
If you're in China, consider configuring a mirror registry in Docker Desktop's settings under "Docker Engine."
Open your cmd or Powershell terminal.
Run the following command to deploy Open WebUI using 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
This command downloads and runs the Open WebUI image in a Docker container.
http://localhost:3000
. This should display the Open WebUI login page.DeepSeek-r1:1.5b
model from the dropdown menu (or whichever DeepSeek model you downloaded).To access your locally deployed DeepSeek instance from anywhere, you can use cpolar to create a secure tunnel to your machine.
Sign up for a cpolar account.
Download and install the cpolar client for Windows.
Log in to the cpolar client using your account credentials by accessing http://localhost:9200
from your browser.
Navigate to "Tunnel Management" -> "Create Tunnel."
Configure the tunnel as follows:
Click "Create Tunnel."
Go to "Status" -> "Online Tunnels" to find the generated public URL.
Use this URL to access your Open WebUI interface from any device with an internet connection.
With these steps, you can now access local DeepSeek installation via the web from any device.
The free version of cpolar generates random URLs that change every 24 hours. For persistent remote access, consider upgrading to a paid cpolar plan to reserve a static subdomain. The process to do that is:
By following these steps, you can harness the power of the DeepSeek R1 AI model on your local Windows machine. Using Ollama for local execution, Docker and Open WebUI for a user-friendly experience and cpolar for secure remote access, you have complete end-to-end control, from model deployment to secure remote access.