How to Install AnyDesk on Debian

AnyDesk provides fast, secure remote desktop access for managing computers from anywhere. Whether you need to provide technical support for family members, access your home workstation from the office, or administer headless servers, AnyDesk delivers low-latency connections with strong encryption. This guide covers two installation methods that work on Debian 11, 12, and 13. By the end, you will have AnyDesk installed, verified, and ready to connect to other devices.

Choose Your AnyDesk Installation Method

Debian offers two approaches for installing AnyDesk from the official repository. Both methods provide the same package with automatic updates, but they differ in how they configure your system.

MethodChannelVersionUpdatesBest For
extrepo (Recommended)Debian’s curated definitionsLatest stableAutomatic via apt upgradeMost users; minimal configuration
Manual RepositoryOfficial AnyDeskLatest stableAutomatic via apt upgradeScripted deployments; learning APT

For most users, the extrepo method is recommended because it handles GPG key management automatically and uses Debian’s curated repository definitions. The manual method provides more control and works identically across all Debian versions without requiring the extrepo package.

Update Debian Before AnyDesk Installation

Before installing new software, refresh your package list to ensure you have the latest metadata:

sudo apt update

After the refresh completes, proceed with your preferred installation method below.

Method 1: Install AnyDesk with extrepo (Recommended)

The extrepo tool is Debian’s official solution for managing external repositories. It automatically handles GPG key downloads, repository configuration, and version detection. As a result, extrepo is the simplest way to install AnyDesk.

Install extrepo and Enable Non-Free Policy

First, install the extrepo package:

sudo apt install extrepo -y

Since AnyDesk is proprietary software, you must enable the non-free policy in extrepo’s configuration before enabling the repository:

sudo sed -i 's/# - non-free/- non-free/' /etc/extrepo/config.yaml

The sed command above uncomments the non-free policy in extrepo’s configuration file. Without this step, extrepo will refuse to enable the AnyDesk repository because AnyDesk uses a proprietary license.

Enable the AnyDesk Repository

With the non-free policy enabled, you can now activate the AnyDesk repository:

sudo extrepo enable anydesk

Running this command downloads the GPG key, creates a DEB822-format sources file at /etc/apt/sources.list.d/extrepo_anydesk.sources, and configures the repository automatically.

Install AnyDesk

Next, update your package index to include the new repository, confirm APT sees the package, and then install AnyDesk:

sudo apt update
apt-cache policy anydesk
sudo apt install anydesk -y

Finally, verify the installation by checking the installed version:

anydesk --version

Expected output:

7.x.x

AnyDesk updates frequently. Your output will show the current version number for your Debian release. On minimal containers or WSL sessions without systemd, installation can fail with a post-install script error about /proc/1/exe; use a standard Debian system or a systemd-enabled container.

Method 2: Install AnyDesk with Manual Repository Configuration

If you prefer explicit control over repository configuration or need to script the installation, you can instead manually add the AnyDesk repository. This method works identically on Debian 11, 12, and 13.

Install Prerequisites

First, install the packages required to download and verify the repository:

sudo apt install ca-certificates curl gnupg -y

These packages provide SSL certificate validation (ca-certificates), secure file downloads (curl), and GPG key handling (gnupg) needed to configure external repositories securely.

Import the AnyDesk GPG Key

Next, download the AnyDesk signing key and convert it to the binary format required by APT:

curl -fsSL https://keys.anydesk.com/repos/DEB-GPG-KEY | sudo gpg --dearmor -o /usr/share/keyrings/anydesk.gpg

The curl command above downloads the ASCII-armored key, converts it to binary format, and saves it directly to the keyrings directory with proper ownership.

Add the AnyDesk Repository

Now, create a DEB822-format sources file for the AnyDesk repository:

cat <<EOF | sudo tee /etc/apt/sources.list.d/anydesk.sources
Types: deb
URIs: https://deb.anydesk.com/
Suites: all
Components: main
Architectures: amd64 i386 armhf
Signed-By: /usr/share/keyrings/anydesk.gpg
EOF

Debian 13 defaults to DEB822 .sources for APT entries. Debian 12 and Debian 11 fully support .sources, though legacy .list files remain common on older installations.

Install AnyDesk

Next, update your package index to include the newly added repository:

sudo apt update

Then, verify that APT recognizes the AnyDesk package from the new repository:

apt-cache policy anydesk

Expected output:

anydesk:
  Installed: (none)
  Candidate: 7.x.x
  Version table:
     7.x.x 500
        500 https://deb.anydesk.com all/main amd64 Packages

Now you can install AnyDesk:

sudo apt install anydesk -y

Finally, confirm the installation succeeded:

anydesk --version

Expected output:

7.x.x

Launch AnyDesk

Once installed, you can start AnyDesk using either the terminal or your desktop environment’s application menu.

Launch from Terminal

To launch AnyDesk, run the following command in any terminal:

anydesk

Launch from Applications Menu

Alternatively, desktop users who prefer a graphical approach can use the application menu:

  1. Open your desktop’s application menu or Activities view.
  2. Type “AnyDesk” in the search field.
  3. Click the AnyDesk icon to launch the application.

AnyDesk Command-Line Reference

AnyDesk also provides several command-line options for automation and scripted deployments. These commands are especially useful for administrators managing multiple systems or integrating AnyDesk with other tools.

Connect to a Remote Device

To initiate a remote session, specify the target’s AnyDesk ID or alias:

anydesk 123456789

Replace 123456789 with the actual AnyDesk ID of the remote device. Alternatively, you can use an alias if one has been configured:

anydesk myworkstation@ad

Connect with Unattended Access Password

If the remote device has Unattended Access configured with a password, you can authenticate automatically:

echo "yourpassword" | anydesk 123456789 --with-password

Security note: Avoid storing passwords in shell history by using environment variables or reading from a secure file instead of echoing passwords directly in commands.

Set Unattended Access Password

You can also configure a password for Unattended Access on the local machine by running the following command as root:

echo "yoursecurepassword" | sudo anydesk --set-password

Once set, remote users can connect without manual approval by providing this password.

Display Client Information

Additionally, you can retrieve useful information about your AnyDesk client:

# Display your AnyDesk ID
anydesk --get-id

# Display your AnyDesk alias (if configured)
anydesk --get-alias

# Check connection status
anydesk --get-status

# Display installed version
anydesk --version

Manage AnyDesk

Update AnyDesk

Because AnyDesk is installed from an APT repository, updates arrive automatically with your regular system updates. However, to update only AnyDesk without upgrading other packages:

sudo apt update
sudo apt install --only-upgrade anydesk

Then verify the new version:

anydesk --version

Remove AnyDesk

If you no longer need AnyDesk, you can uninstall it and remove its configuration files:

sudo apt remove --purge anydesk -y
sudo apt autoremove -y

The --purge flag removes system-wide configuration files, while autoremove cleans up any orphaned dependencies that were installed automatically with AnyDesk.

Remove the AnyDesk Repository

If you do not plan to reinstall AnyDesk, also remove the repository configuration and GPG key:

If you used extrepo:

sudo extrepo disable anydesk
sudo rm -f /etc/apt/sources.list.d/extrepo_anydesk.sources
sudo rm -f /var/lib/extrepo/keys/anydesk.asc

If you used manual repository configuration:

sudo rm -f /etc/apt/sources.list.d/anydesk.sources
sudo rm -f /usr/share/keyrings/anydesk.gpg

After removing the repository files, refresh your package cache:

sudo apt update

Remove User Data

Warning: The following command permanently deletes your AnyDesk user data, including connection history, saved addresses, and local settings. This action cannot be undone.

If you want a complete cleanup, remove AnyDesk’s user-specific data directory:

rm -rf ~/.anydesk

Verify Removal

Finally, confirm that AnyDesk has been completely removed:

apt-cache policy anydesk

Expected output after complete removal:

anydesk:
  Installed: (none)
  Candidate: (none)
  Version table:

Conclusion

You now have AnyDesk installed on your Debian system with automatic updates from the official repository. Both the extrepo and manual methods provide identical functionality, so choose whichever fits your workflow. For remote support scenarios, consider configuring Unattended Access so you can connect without requiring someone to approve the connection manually. If you manage firewalls on your system, AnyDesk typically works without additional port configuration because it uses outbound connections to relay servers.

For related remote access and security topics, see our guides on enabling SSH on Debian and configuring UFW firewall on Debian.

Leave a Comment