Install Docker on Debian 13 “Trixie” — The Easy Way

Docker has become one of the go-to tools for running applications in isolated, lightweight containers. It’s fast, efficient, and works just as well on a laptop as it does on a massive server cluster.

Debian, meanwhile, is one of the most trusted Linux distributions in the world. Known for its rock-solid stability, it’s the foundation for countless other systems, including Ubuntu. If you combine Debian’s stability with Docker’s flexibility, you get a container platform that’s both reliable and future-proof.

If you’re running the freshly released Debian 13 “Trixie” and want to set up Docker, you’re in the right place. This step-by-step guide will walk you through the process from start to finish — tested in a clean environment so you can follow along with confidence.

Step 1: Update Your Package List

First, refresh your Debian system so you’re working with the latest package information.

sudo apt update

If updates are available, install them before moving on. This ensures you don’t run into conflicts later.


Step 2: Install Required Packages

Before adding Docker’s repository, we need a few helper packages that enable secure communication over HTTPS.

sudo apt install apt-transport-https ca-certificates curl

These make sure APT can connect safely to external repositories.


Step 3: Add Docker’s GPG Key

Debian already includes Docker in its repositories. But here’s the catch — those versions may lag behind the latest official releases.

We’ll install Docker from its official repository so you always get the newest version automatically. That starts with adding Docker’s GPG key to verify downloads.

curl -fsSL <https://download.docker.com/linux/debian/gpg> | sudo gpg --dearmor -o /usr/share/keyrings/docker.gpg

No output means it worked fine.


Step 4: Add the Docker Repository

Next, point APT to Docker’s official Debian repository:

echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker.gpg] <https://download.docker.com/linux/debian> trixie stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null

Now refresh your package list again so Debian recognizes the new source:

sudo apt update

You can double-check the repo is active with:

apt-cache policy


Step 5: Install Docker

Time for the main event. Install Docker and its related components with:

sudo apt install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin

Here’s what each part does:

  • docker-ce – The Docker engine.
  • docker-ce-cli – Command-line tool to interact with Docker.
  • containerd.io – Core container runtime.
  • docker-buildx-plugin – Extended image building, including multi-platform support.
  • docker-compose-plugin – Manage multi-container apps via YAML.

When prompted, confirm with Y. The whole process should take under a minute.


Step 6: Verify Docker Is Running

After installation, Docker starts automatically. Check its status:

sudo systemctl is-active docker

Then run the classic “Hello World” container to confirm everything works:

sudo docker run hello-world

If you see a friendly message, congratulations — Docker is up and running on Debian 13.


Step 7: Run Docker Without sudo (Optional)

By default, only root or sudo users can run Docker commands. If you want to run them as a regular user:

sudo usermod -aG docker ${USER}
newgrp docker

Now you can run docker without sudo — but note that you’ll need to log out and back in (or reboot) for the change to stick permanently.


Wrapping Up

Installing Docker on Debian 13 “Trixie” is quick and painless once you know the steps. In just a few commands, you’ve gone from a fresh system to a fully functional container platform.

From here, you can explore Docker Compose for multi-container setups, pull pre-built images from Docker Hub, or build your own. For deeper dives, the official Docker documentation is an excellent next step.

Now you’ve got Debian’s legendary stability paired with Docker’s flexibility — a perfect match for running containers smoothly for years to come.

David Cao
David Cao

David is a Cloud & DevOps Enthusiast. He has years of experience as a Linux engineer. He had working experience in AMD, EMC. He likes Linux, Python, bash, and more. He is a technical blogger and a Software Engineer. He enjoys sharing his learning and contributing to open-source.

Articles: 538

Leave a Reply

Your email address will not be published. Required fields are marked *