• apt is a newer version of apt-get
  • They are both based on the APT (Advanced Packaging Tool) system.
  • Both tools used to install, remove, and update software packages on Debian-based Linux distributions.
  • For the most part, yes, you can use apt and apt-get interchangeably.
  • The commands are mostly the same, and they will usually produce the same results.
  • However, there are some cases where the two tools will behave differently.

Commands

aptapt-getcommand function
apt installapt-get installInstalls a new package
apt removeapt-get removeRemoves a package
apt purgeapt-get purgeRemoves package with configuration
apt updateapt-get updateUpdates the list of available packages
apt upgradeapt-get upgradeUpdates all installed packages to the latest version
apt full-upgradeapt-get dist-upgradeUpgrades packages with auto-handling of dependencies
apt autoremoveapt-get autoremoveRemoves packages that are no longer needed
apt searchapt-cache searchSearches for a package
apt showapt-cache showShows package details

Differences

Featureapt-getapt
Dependency resolutionSimple dependency resolution.Complex dependency resolution with suggested software installations.
Error messagesMore helpful error messagesLess helpful error messages
Package versions on the file systemOlder versions of packages remain on the file system when using apt-get upgrade.Older versions of packages are deleted from the file system when using apt upgrade.
Preferred tool for most usersYesNo
Printed output from operationsPrints basic output from each apt-get command to the user, without much detail.Prints verbose output from each apt command to the user for more information on operations, including a progress bar on tasks.
Search capabilitiesNo. Users must use apt-cache package management commands instead for search.Yes.
User-friendlinessMore user-friendlyLess user-friendly
Year of release19982014

References