Samiul Islam

System Administrator

Website Developer

Graphics Designer

Content Maker

Apps Developer

Samiul Islam

System Administrator

Website Developer

Graphics Designer

Content Maker

Apps Developer

Blog Post

Enable SSH root login on Ubuntu

April 1, 2025 Tips & Trics, Tutorial
Enable SSH root login on Ubuntu

To bypass the standard SSH login procedure, which requires logging in as a regular user before gaining root access, you can modify the SSH configuration to allow direct root logins. This tutorial details how to enable this functionality on Ubuntu 20.04 Server/Desktop. SSH itself provides secure network services like remote command-line access.

In this tutorial you will learn:

How to enable root access to SSH
How to restart SSH service

Step 1: Open the /etc/ssh/sshd_config file with administrative privileges and change the following line:

FROM:
#PermitRootLogin prohibit-password
TO:
PermitRootLogin yes

Step 2: Restart SSH service:

$ sudo systemctl restart ssh
Write a comment