Black Friday: Save 10% for life on all of our VPS plans, now through Cyber Monday

10% off on selected plans for as long as you keep the service · new orders · up to 10 uses per customer · ends Dec 1, 2026, 12:00 AM EST.

See plans
Guideschevron_rightServers

Servers · 8 min read · Updated

How to Self-Host the Qdrant Vector Database

To self-host Qdrant, run the official qdrant/qdrant Docker image with its storage on a local NVMe volume, publish ports 6333 (REST and dashboard) and 6334 (gRPC) to 127.0.0.1 only, and set QDRANT__SERVICE__API_KEY, because Qdrant starts with no authentication. Size the server's memory from your vector count and dimensions, and back up with snapshots.

1. Size the Server

Qdrant's capacity-planning guide adds up memory per part, then about 20% headroom:

Qdrant's memory estimate, per its capacity-planning guide
PartFormula
Dense vectors (float32)points × replicas × dimensions × 4 bytes
Search index (HNSW, m = 16)points × replicas × 16 × 2 × 4 bytes × 1.2
Point IDspoints × replicas × 52 bytes

On a single server the replication factor is 1, so a million 768-dimension vectors come to roughly 3 GB for the vectors themselves. Payloads (the text and metadata stored with each vector) are memory-mapped from disk by default and loaded when needed. Qdrant notes that keeping half as many vectors in memory roughly doubles search latency, so give it the memory if speed matters. It wants local SSD or NVMe, with at least 50,000 IOPS for vectors kept on disk; every VPS and dedicated server of ours uses local storage.

2. Run Qdrant With an API Key

On Ubuntu 24.04, after securing the server and installing Docker, create ~/qdrant/compose.yaml:

services:
  qdrant:
    image: qdrant/qdrant
    restart: always
    ports:
      - "127.0.0.1:6333:6333"     # REST API and dashboard, on the server only
      - "127.0.0.1:6334:6334"     # gRPC
    environment:
      QDRANT__SERVICE__API_KEY: ${QDRANT_API_KEY}
    volumes:
      - ./qdrant_data:/qdrant/storage
      - ./qdrant_snapshots:/qdrant/snapshots
cd ~/qdrant
echo "QDRANT_API_KEY=$(openssl rand -hex 32)" > .env
docker compose up -d
curl -s -H "api-key: $(grep -oP '(?<==).*' .env)" http://127.0.0.1:6333/collections

Binding to 127.0.0.1 matters: Docker publishes ports past ufw, so a plain 6333:6333 would put an open database on the internet (see why ufw does not block Docker ports). Pin the image to a version tag once you are happy with it, so updates happen when you choose.

3. Store and Search Vectors

From Python on the same server, with pip install qdrant-client:

import os
from qdrant_client import QdrantClient
from qdrant_client.models import Distance, VectorParams, PointStruct

client = QdrantClient(url="http://localhost:6333", api_key=os.environ["QDRANT_API_KEY"])

client.create_collection(
    collection_name="docs",
    vectors_config=VectorParams(size=4, distance=Distance.DOT),
)
client.upsert(
    collection_name="docs",
    wait=True,
    points=[PointStruct(id=1, vector=[0.05, 0.61, 0.76, 0.74], payload={"city": "Berlin"})],
)
hits = client.query_points(collection_name="docs", query=[0.2, 0.1, 0.9, 0.7], limit=3).points
print(hits)

In a real application, size is your embedding model's dimension (768 or 1,536 are common), and the vectors come from that model. To browse collections in the dashboard, open an SSH tunnel and visit http://localhost:6333/dashboard:

ssh -L 6333:127.0.0.1:6333 [email protected]

4. Reach It From Other Servers

When your application runs elsewhere, do not publish 6333 to the internet. Between our servers in the same location, use private networking and bind the port to the private address instead of 127.0.0.1; elsewhere, use WireGuard. For read-only clients, Qdrant also accepts a second key, QDRANT__SERVICE__READ_ONLY_API_KEY. Across any network you do not control, turn on Qdrant's TLS as well, so the API key is not sent in the clear.

Backups With Snapshots

KEY=$(grep -oP '(?<==).*' ~/qdrant/.env)
curl -X POST -H "api-key: $KEY" http://127.0.0.1:6333/collections/docs/snapshots
ls -R ~/qdrant/qdrant_snapshots/

Each snapshot is a single file in the snapshots folder. Copy it off the server, for example to a storage box or object storage, and delete old ones. Snapshots restore only into the same or the next minor version of Qdrant, so take a fresh one before each upgrade. To run the language model behind your RAG app on your own hardware too, see Open WebUI with Ollama or serving an LLM API.

Common Questions

  • What is Qdrant?

    An open-source vector database: it stores embeddings, the lists of numbers an AI model turns text or images into, and finds the closest ones fast. It is the search step behind retrieval-augmented generation (RAG), semantic search and recommendations.

  • How much memory does Qdrant need?

    Qdrant's capacity-planning guide works it out from the data: for vectors, the number of points times the dimensions times 4 bytes for float32, plus the search index and payloads, then about 20% headroom. Its own example, one million 768-dimension vectors kept twice (replication 2), needs about 5.7 GB for the vectors alone.

  • Is Qdrant secure by default?

    No. Its quickstart says it starts with no encryption or authentication, so anyone who can reach the port can read and change your data. Set an API key, keep the ports off the internet, and use TLS when it is reached across a network.

  • Can it store data on network storage or S3?

    Not its live data: Qdrant's documentation says it won't work with network file systems such as NFS or object storage such as S3, and recommends local SSD or NVMe. Snapshots, its backups, can go to S3.

Plans and prices

VPS Plans

KVM servers with local NVMe storage and full root access for vector search.

See all plans
  • Bronze

    3 vCPU · 6 GB RAM · 75 GB NVMe

    2 TB transfer

    $37.50/mo

    Configure inAshburnDallas
  • Silver

    4 vCPU · 8 GB RAM · 100 GB NVMe

    4 TB transfer

    $46.50/mo

    Configure inAshburnDallas
  • Gold

    6 vCPU · 12 GB RAM · 150 GB NVMe

    6 TB transfer

    $60.00/mo

    Configure inAshburnDallas
  • Diamond

    8 vCPU · 16 GB RAM · 200 GB NVMe

    8 TB transfer

    $73.50/mo

    Configure inAshburnDallas

Network port: 10 Gbps in Ashburn, VA, 50 Gbps in Dallas, TX. Pick the location when you configure.

Keep Reading

All guides