---
title: "How to disable Two-Factor Authentication (2FA) on Cyberpanel login."
description: "Sometimes you may be trying to access Cyberpanel but into a screen that asks you to input a Two-Factor Authentication (2FA), which you have never set and yet you do not know where to get. Well, you can as well…"
url: "https://truehost.com/support/knowledge-base/how-to-disable-two-factor-authentication-2fa-on-cyberpanel-login/"
updated: "2024-10-15"
category: Cloud servers in Kenya
---

# How to disable Two-Factor Authentication (2FA) on Cyberpanel login.

Sometimes you may be trying to access Cyberpanel but into a screen that asks you to input a Two-Factor Authentication (2FA), which you have never set and yet you do not know where to get. Well, you can as well disable it. Please be guided below;

#### Prerequisites:

- **SSH Access** to the server running CyberPanel.
- **Root or Sudo Privileges** for performing administrative tasks on the server.

**Step** 1: **Connect to the Server via SSH**

- Connect to your server using SSH. If you do not know how to, refer **[here](https://truehost.com/support/knowledge-base/how-to-access-a-server-via-ssh-terminal/)**

**Step 2: Enter the MySQL Command Line**

- Once logged into your server, use the following command to retrieve the MySQL root password stored by CyberPanel and log into MySQL as the root user:

```
MYSQL_PWD=`cat /etc/cyberpanel/mysqlPassword` mysql -uroot
```

![](https://truehost.com/support/wp-content/uploads/2024/10/image-285.png)

**Step 3: Switch to the CyberPanel Database**

- To start interacting with CyberPanel’s database, enter the following command:

```
USE cyberpanel;
```

- You should see a message indicating the database has been changed.

![](https://truehost.com/support/wp-content/uploads/2024/10/image-286.png)

**Step 4: Disable 2FA for the Admin Account**

- To disable 2FA for the admin account, execute the following SQL command:

```
UPDATE `loginSystem_administrator` SET `twoFA` = '0' WHERE `loginSystem_administrator`.`id` = 1;
```

- You will see a success message such as the one in the image below

![](https://truehost.com/support/wp-content/uploads/2024/10/image-287.png)

- Even if no rows were changed, the command will still disable 2FA for the admin account as long as the matched rows is greater than 0.

**Step 5 : Clear Browser Cache then Log Back into CyberPanel**

- Before attempting to log back into CyberPanel, clear your browser cache. This will ensure that any cached 2FA login requests are removed.
- Now try to **[access your CyberPanel](https://truehost.com/support/knowledge-base/how-to-access-cyberpanel/)** login page using the admin credentials. Two-Factor Authentication should no longer be required.
