How to Upgrade Debian 12 to Debian 13 Trixie

Debian 13, codenamed “Trixie”, was released on August 9, 2025. It ships with Linux kernel 6.12 LTS, GNOME 48, KDE Plasma 6, GCC 14.2, Python 3.13, and over 14,100 new packages. Debian 13 will receive full support until August 2028, with Long Term Support (LTS) extending to June 2030.
This guide walks you through upgrading Debian 12 “Bookworm” to Debian 13 “Trixie” via the command line.
Prerequisites
You need to be logged in as root or a user with sudo privileges to perform the upgrade. You can only upgrade to Debian 13 from Debian 12. If you are running an older Debian version, upgrade to Debian 12 first.
Back Up Your Data
Before starting a major version upgrade, make sure you have a complete backup of your data. If you are running Debian on a virtual machine, take a full system snapshot so you can restore quickly if anything goes wrong.
Update Currently Installed Packages
Before changing the source repositories, bring your existing Debian 12 system fully up to date.
Check whether any packages are marked as held back, which could interfere with the upgrade:
sudo apt-mark showholdIf there are held packages, either unhold them with sudo apt-mark unhold package_name or make sure they will not cause issues during the upgrade.
Refresh the package index and upgrade all installed packages:
sudo apt update
sudo apt upgradePerform a major version upgrade of the installed packages:
sudo apt full-upgradeRemove automatically installed dependencies that are no longer needed:
sudo apt autoremoveUpdate the Sources List
The upgrade works by pointing your APT repositories from bookworm to trixie.
Open /etc/apt/sources.list with your text editor
and replace every instance of bookworm with trixie. You can also do this with a single sed
command:
sudo sed -i 's/bookworm/trixie/g' /etc/apt/sources.listIf you have third-party repository files under /etc/apt/sources.list.d/, disable them before the upgrade. They may not be compatible with Debian 13 and can cause errors.
bookworm-backports entries from your sources files before upgrading. You can add trixie-backports after the upgrade is complete.After editing, your /etc/apt/sources.list should look similar to this:
deb https://deb.debian.org/debian/ trixie main contrib non-free non-free-firmware
# deb-src https://deb.debian.org/debian/ trixie main contrib non-free non-free-firmware
deb https://deb.debian.org/debian/ trixie-updates main contrib non-free non-free-firmware
# deb-src https://deb.debian.org/debian/ trixie-updates main contrib non-free non-free-firmware
deb https://security.debian.org/debian-security/ trixie-security main contrib non-free non-free-firmware
# deb-src https://security.debian.org/debian-security/ trixie-security main contrib non-free non-free-firmwareYou can find a full list of Debian mirror addresses on the official mirrors page .
Upgrade to Debian 13 Trixie
Set the terminal output to English to make it easier to follow any prompts:
export LC_ALL=CUpdate the package index with the new Trixie repositories:
sudo apt updateIf you see errors related to third-party repositories, fix or disable them before continuing.
Run the initial upgrade. This upgrades packages that do not require installing or removing other packages:
sudo apt upgrade --without-new-pkgsDuring the upgrade, you may be asked whether services should be automatically restarted:
Restart services during package upgrades without asking?You may also see prompts about configuration files. If you have not made custom changes to a file, it is safe to accept the package maintainer’s version. If you have made changes, keep the current version to avoid losing your customizations.
Once the initial upgrade finishes, run the full upgrade. This installs new packages, removes obsolete ones, and resolves any remaining dependency changes between Debian 12 and 13:
sudo apt full-upgradeThe upgrade may take some time depending on the number of packages, your hardware, and your internet speed.
When it completes, clean up packages that are no longer needed:
sudo apt autoremoveReboot your system to load the new kernel:
sudo systemctl rebootVerify the Upgrade
After the system boots, log in and check the Debian version :
lsb_release -aNo LSB modules are available.
Distributor ID: Debian
Description: Debian GNU/Linux 13 (trixie)
Release: 13
Codename: trixieYou can also verify the kernel version:
uname -rThe output should show a 6.12.x kernel.
Troubleshooting
Third-party repository errors during apt update
Disable any third-party sources under /etc/apt/sources.list.d/ before the upgrade. Re-enable them one by one after the upgrade completes, checking that each repository supports Debian 13.
“Packages have been kept back” during upgrade
This is normal during the initial apt upgrade --without-new-pkgs step. The subsequent apt full-upgrade resolves these held-back packages by installing new dependencies or removing conflicting ones.
Services fail to start after reboot
Check the service logs with journalctl -xe and the service status with systemctl status service_name. Configuration file format changes between major versions are a common cause. Compare your config with the package maintainer’s version in /etc/*.dpkg-dist files.
Conclusion
Your system is now running Debian 13 Trixie. Re-enable any third-party repositories you disabled, verify that your critical services are running, and consider adding trixie-backports to your sources if you need newer package versions. For a full list of known issues and detailed upgrade notes, see the official Debian 13 release notes
.
Tags
Linuxize Weekly Newsletter
A quick weekly roundup of new tutorials, news, and tips.
About the authors

Dejan Panovski
Dejan Panovski is the founder of Linuxize, an RHCSA-certified Linux system administrator and DevOps engineer based in Skopje, Macedonia. Author of 800+ Linux tutorials with 20+ years of experience turning complex Linux tasks into clear, reliable guides.
View author page