When working with Debian systems, it’s crucial to have the right APT sources.list configuration for accessing software packages. This is especially true in situations where you’re setting up a new system, recovering from a failure, or maintaining older versions of Debian. The APT sources.list file tells the Advanced Package Tool (APT) where to fetch packages from. This guide provides a comprehensive reference for setting up the APT sources.list on Debian systems from version 7 (Wheezy) through version 13 (Trixie), covering both current and archived releases.
Table of Contents
In this tutorial you will learn:
- How to configure APT sources.list for Debian 7 through 13
- The difference between active mirrors and archived repositories
- Understanding repository components (main, contrib, non-free, non-free-firmware)
- How to modify sources.list when Debian versions become archived

| Category | Requirements, Conventions or Software Version Used |
|---|---|
| System | Debian 7 (Wheezy), 8 (Jessie), 9 (Stretch), 10 (Buster), 11 (Bullseye), 12 (Bookworm), 13 (Trixie) |
| Software | APT (Advanced Package Tool) |
| Other | Internet connection for accessing APT repositories |
| Conventions | # – requires given linux commands to be executed with root privileges either directly as a root user or by use of sudo command$ – requires given linux commands to be executed as a regular non-privileged user |
APT Sources.list for Current Debian Releases
The following configurations work with active Debian mirrors. Copy and paste these directly into your /etc/apt/sources.list file.
UNDERSTANDING REPOSITORY COMPONENTS
Debian repositories are divided into components: main contains fully free software supported by Debian, contrib includes free software that depends on non-free packages, non-free contains software that doesn’t meet Debian’s free software guidelines, and non-free-firmware (introduced in Debian 12) separates hardware firmware from other non-free software. Enable only the components you need, most users require at least main and non-free-firmware for hardware support.
Debian 13 (Trixie)
deb http://deb.debian.org/debian/ trixie main non-free contrib non-free-firmware deb http://security.debian.org/debian-security trixie-security main non-free contrib non-free-firmware deb http://deb.debian.org/debian/ trixie-updates main non-free contrib non-free-firmware
Debian 12 (Bookworm)
deb http://deb.debian.org/debian bookworm main contrib non-free non-free-firmware deb http://deb.debian.org/debian bookworm-updates main contrib non-free non-free-firmware deb http://security.debian.org/debian-security bookworm-security main contrib non-free non-free-firmware
Debian 11 (Bullseye)
deb http://deb.debian.org/debian bullseye main contrib non-free deb http://deb.debian.org/debian bullseye-updates main contrib non-free deb http://security.debian.org/debian-security bullseye-security main contrib non-free
APT Sources.list for Archived Debian Releases
When Debian versions reach end-of-life, their repositories are moved to archive servers. Replace the standard mirror URLs with archive.debian.org to continue accessing packages. Note that archived versions no longer receive security updates.
Debian 10 (Buster) – Archived
deb http://archive.debian.org/debian/ buster main non-free contrib deb http://archive.debian.org/debian/ buster-updates main non-free contrib deb http://archive.debian.org/debian-security buster/updates main non-free contrib
Debian 9 (Stretch) – Archived
deb http://archive.debian.org/debian/ stretch main contrib non-free deb http://archive.debian.org/debian/ stretch-proposed-updates main contrib non-free deb http://archive.debian.org/debian-security stretch/updates main contrib non-free
Debian 8 (Jessie) – Archived
deb http://archive.debian.org/debian/ jessie main contrib non-free deb http://archive.debian.org/debian-security jessie/updates main contrib non-free
Debian 7 (Wheezy) – Archived
deb http://archive.debian.org/debian/ wheezy main contrib non-free deb http://archive.debian.org/debian-security wheezy/updates main contrib non-free
Conclusion
Having the correct APT sources.list configuration is fundamental for Debian system setup and maintenance. This guide covers all Debian releases from version 7 (Wheezy) through version 13 (Trixie), providing copy-paste ready configurations for both current and archived versions. For current releases, always ensure your sources.list includes security repositories to receive critical updates. When working with archived versions, remember that these systems no longer receive security patches and should be upgraded when possible. For more detailed information about Debian package management, check our related guides.
Frequently Asked Questions
- How do I edit the sources.list file? Open a terminal and run
su -to become root (or usesudoif configured), then edit the file withnano /etc/apt/sources.list. After saving changes, runapt updateto refresh the package lists. - What does “Release file expired” error mean? This error occurs with archived Debian versions because the Release files have validity dates that have passed. Add
Acquire::Check-Valid-Until "false";to/etc/apt/apt.confor run APT with-o Acquire::Check-Valid-Until=falseoption to bypass this check. - Should I include deb-src lines in my sources.list? Only if you need to download and compile source packages. Most users don’t need source repositories, and omitting them speeds up
apt update. Adddeb-srclines mirroring yourdebentries only when you need to build packages from source. - What is the difference between non-free and non-free-firmware? Starting with Debian 12, firmware packages were separated into their own
non-free-firmwarecomponent. This allows users to enable just hardware firmware without enabling all non-free software. For older Debian versions, firmware packages remain in thenon-freecomponent. - How do I know when my Debian version will be archived? Debian provides approximately three years of support for each stable release, plus two additional years of LTS support. Check the Debian LTS wiki page for current end-of-life dates and plan your upgrades accordingly.