Security Spanish version

Support article

How to Enable Two-Factor Authentication (2FA) (Step by Step)

Enable two-factor authentication (2FA) on your accounts: cPanel, WordPress, Google and more. Protect your access with a second security layer.

Published: 12/07/2026 Updated: 12/07/2026

Introduction

Two-factor authentication (2FA) is the most effective security measure you can take to protect your accounts. Even if someone steals your password, they can’t enter without the second factor.

In this article you’ll see what it is, how it works and how to enable it on your most important accounts.

What two-factor authentication is

Two-factor authentication adds a second security layer to your access. Instead of just the password (something you know), you also need something you have (your phone).

How it works

  1. You type your username and password.
  2. The system asks for a verification code.
  3. The code arrives on your phone (by app, SMS or email).
  4. You enter the code and log in.

Without the code, even if someone has your password, they can’t enter. It’s like having two locks on the door.

Types of second factor

TypeHow it worksSecurity
Authenticator app (Google Authenticator, Authy)Generates codes every 30 secondsVery high
SMSYou receive a code by messageMedium (can be intercepted)
EmailYou receive a code by emailMedium
Physical key (YubiKey)USB device you tapMaximum
App pushYou accept in a notificationHigh

Authenticator apps (Google Authenticator, Authy, Microsoft Authenticator) are the most balanced option: secure, free and without depending on mobile network.

Where to enable 2FA

On cPanel

  1. Log in to cPanel.
  2. Find Two-Factor Authentication.
  3. Scan the QR code with your authenticator app.
  4. Enter the generated code to confirm.
  5. Save the backup codes.

At miHosting, you can enable 2FA on cPanel to protect your hosting account.

On WordPress

WordPress doesn’t include 2FA by default. Use a plugin:

  • Wordfence Login Security (free).
  • Two Factor (free).
  • WP 2FA (free).

Install the plugin, configure your authenticator app and enable 2FA for your administrator user.

On Google

  1. Go to myaccount.google.com.
  2. Go to Security → Two-Step Verification.
  3. Enable it and follow the steps.

On Outlook/Microsoft

  1. Go to account.microsoft.com.
  2. Go to Security → Advanced security options.
  3. Enable two-step verification.

On social media

Facebook, Instagram, X (Twitter), LinkedIn and all major social networks allow enabling 2FA in their security settings.

Useful tips

  • Enable 2FA on all your important accounts. Especially email, hosting and banks.
  • Use an app, not SMS. Apps are more secure than SMS.
  • Save backup codes. If you lose your phone, backup codes let you log in.
  • Don’t use the same code for everything. Each account should have its own 2FA.
  • Be careful when changing phones. Before changing, configure 2FA on the new one or disable it on the old one.

Common problems

I lost my phone with the authenticator app

Use the backup codes you saved when configuring 2FA. If you don’t have them, you’ll have to contact each account’s support service to verify your identity.

The code doesn’t work

Codes expire every 30 seconds. Make sure your phone’s time is synchronized. If not, apps generate incorrect codes.

I don’t want 2FA because it’s uncomfortable

Think about how uncomfortable it would be to have your account hacked. 2FA takes 5 seconds and saves you many headaches.

2FA blocks my access

Always save backup codes. If you get blocked, contact support.

Frequently asked questions

Is 2FA free?

Yes, both authenticator apps and 2FA on most services are free.

Do I need internet for the code?

No. Authenticator apps generate codes without connection. SMS does need coverage.

Can I use the same 2FA on several accounts?

Not the same code, but the same app. Each account generates its own code.

Does my miHosting hosting support 2FA?

Yes, you can enable 2FA on cPanel. Open a ticket if you need help.

Does 2FA protect from everything?

Not from everything, but it drastically reduces the risk. An attacker would need your password AND your phone.

2FA: the most effective measure

Two-factor authentication is the most effective security measure you can take. It’s free, it’s fast and it protects you from 99% of stolen password attacks.

If you need help enabling 2FA on your miHosting account, open a ticket from your client panel.