Two-factor authentication (2FA): what it is and how to turn it on
What two-factor authentication is, how it works, which second factor is most secure (SMS, app, hardware key, passkey), how to turn it on, where to start and how to protect yourself from attacks that try to get around it

Passwords leak. They leak in breaches of websites you'd never suspect, they're stolen with phishing emails, and they're guessed by bots that try millions of combinations. If the only thing protecting your email, bank or website is a password, all it takes is for that password to fall into the wrong hands.
Two-factor authentication adds a second lock. Even if someone knows your password, they can't get in without the second factor, which is usually your phone. In this article you'll learn what two-factor authentication is, how it works, which kinds of second factor are secure and which are less so, how to turn it on and where to start. You'll also see the attacks scammers use to try to get around it, and how to protect yourself from them.
In short
- Two-factor authentication (2FA) asks for a second, separate proof of identity on top of your password, most often a code from your phone.
- Even if your password leaks, an attacker can't log in without the second factor.
- An authenticator app is more secure than SMS, and a hardware security key or a passkey is the most secure of all.
- Turn it on for your email first, because that's where passwords for everything else get reset.
- Keep your backup codes somewhere safe and never share a code with anyone.
What is two-factor authentication
Two-factor authentication, or 2FA for short, is a way of logging in that requires you to prove who you are in two different ways. The first is your password. The second is something separate from it, most often a one-time code from your phone, a notification you approve or a physical security key.
The idea is simple: to get into your account, an attacker needs both things at once. Stealing a password from the other side of the world is easy. Stealing your phone as well is much harder. That's why two-factor authentication stops the vast majority of automated attacks and password theft.

You'll come across other names for the same thing: two-step verification, 2-step verification, two-factor login or multi-factor authentication (MFA).
How it works: something you know, have and are
In security, there are three kinds of proof, called factors:
- Something you know – a password, a PIN or the answer to a secret question;
- Something you have – a phone, a hardware key or a bank card;
- Something you are – a fingerprint or your face.
Two-factor authentication combines two different kinds. The most common combination is a password plus a phone. It matters that the factors are of different kinds. Two passwords are not two-factor protection, because both can be stolen in exactly the same way.
In practice, logging in looks like this: you enter your username and password, the system checks them and then asks for the second factor. You open the app on your phone, type in the six-digit code it shows or tap "Approve", and you're in. On a trusted device, most services can remember your choice, so you won't have to enter a code every time you log in.
Why a password alone isn't enough
Most people use the same password, or slight variations of it, in lots of places. When one of those sites is breached, the database of passwords is sold and bots start trying it everywhere: in email, on social media, in online shops. This attack is called credential stuffing, and it works precisely because passwords are reused.
Passwords are also stolen directly. A phishing email sends you to a fake login page that looks exactly like the real one, and you type in your password yourself. Malware on your computer records what you type. A weak password is simply guessed.

Two-factor authentication solves the problem by making a stolen password useless on its own. An attacker may know it, but without the second factor the door stays shut. That's why it's one of the few security measures that delivers such a big effect for so little effort.
Types of second factor
Not all second factors are equally secure. These are the main types, from weakest to strongest.
SMS codes
When you log in, you receive a code by text message. It's the most widespread and easiest option, because it doesn't require anything extra. It's much better than a password alone, but it's the weakest of all second factors. Scammers can persuade a mobile operator to move your number to their own SIM card (a so-called SIM swap) and then receive your codes too. Text messages can also arrive late or not at all when you're abroad.
Authenticator apps
Apps such as Google Authenticator, Microsoft Authenticator, 2FAS or Aegis generate a new six-digit code every 30 seconds. The code is calculated on the phone itself from a secret key saved during setup via a QR code, and it never travels over the mobile network. That means a SIM swap doesn't help an attacker, and the app works even without signal. It's the best choice for most people.

Push notifications
Instead of a code, you get a notification asking "Are you trying to sign in?" and tap "Approve" or "Deny". It's convenient and fast. The risk is that, worn down by constant notifications, people sometimes approve a login they didn't make. Newer systems ask you to type in a number shown on the login screen, which almost removes that risk.
Hardware security keys
A small USB or NFC device that you plug into your computer or hold against your phone. The key checks the website's address before confirming the login, so it won't work on a fake phishing page. That makes it the most secure second factor. It's ideal for administrators, finance teams and any account that gives access to money or to the whole company.
Passkeys
Passkeys replace the password altogether. You log in with your fingerprint, face or your device's PIN, and the device proves who you are with a protected cryptographic key. Like hardware keys, they don't work on fake websites. More and more services support them, and they're gradually becoming the standard.
| Second factor | Security | Convenience | Protects against phishing |
|---|---|---|---|
| SMS code | low | high | no |
| Authenticator app | good | high | not fully |
| Push with number matching | good | very high | partly |
| Hardware key | very high | medium | yes |
| Passkey | very high | very high | yes |
Two-factor, two-step or multi-factor
The three terms are often used interchangeably, but there's a small difference. Two-factor authentication requires two factors of different kinds, such as a password and a phone. Two-step verification simply means the login goes through two steps, and sometimes both are of the same kind. Multi-factor authentication (MFA) is the general term for two or more factors.
For an ordinary user, the difference is small. If a service offers "2-step verification" with an app or a key, you're getting genuine two-factor protection.
How to turn on two-factor authentication
Menus vary, but the steps are almost the same everywhere:
- Log in to your account and open the security or sign-in settings.
- Look for "Two-factor authentication", "2-Step Verification" or "2FA".
- Choose a method. If you have a choice, go for an authenticator app or a security key rather than SMS.
- Scan the QR code with the app on your phone and enter the code it shows to confirm.
- Write down or download your backup codes and keep them somewhere safe.
- Log out and back in to check that everything works.
In a Google Account, the setting is on the "Security" tab under "2-Step Verification". In a Microsoft account, it's under "Security" as "Two-step verification". Social networks usually keep it in their security and login settings. In your hosting control panel and at your domain registrar, look for the account security section too.
Where to turn it on first
If you can't turn on two-factor authentication everywhere at once, start with the accounts that unlock everything else:
- Your email – it's where passwords for almost every other service are reset. Whoever controls your inbox can take over your other accounts too.
- Your password manager – if you use one, it holds the keys to everything.
- Your bank and payment services – in the EU, banks already require strong authentication for logins and payments, but check which method you've chosen.
- Your domain registrar and hosting – whoever gets in there can redirect your domain, change your email or delete your site. We explain what losing control of a domain means in our article what is a domain name.
- Your website's admin area – for WordPress sites, it's one of the most important measures, alongside the rest in our article WordPress security.
- Social media – especially company pages used for advertising and talking to customers.
Backup codes and changing phones
The most common reason people give up on two-factor authentication is the fear of losing their phone and getting locked out. The answer is backup codes. When you turn 2FA on, the service gives you a list of one-time codes, each of which can replace the second factor once.
Keep them separate from your phone: printed and stored somewhere safe, or in your password manager. Don't keep them as a photo on the same phone and don't email them to yourself.

Before you change phones, move your codes across. Most authenticator apps have a transfer or cloud backup feature, while with some you'll need to turn 2FA off and on again for each account. Don't delete the app from your old phone until you've checked that the new one generates working codes everywhere. Where possible, add a second method as well, such as a backup security key or a second phone.
Two-factor authentication for businesses
In a business, one hacked account can cost far more than a personal one. Using an employee's stolen email, scammers write to customers and suppliers, ask for payments to new bank accounts or get into shared documents. That's why two-factor authentication should be mandatory for everyone, not just recommended.
- turn it on for company email, shared drives and payment systems;
- give administrators and the finance team hardware keys or passkeys;
- don't share one account between several people; give everyone their own, with its own protection;
- when someone leaves, revoke their access straight away and review which devices were linked to their accounts.
If you're just setting up business email on your own domain, see our article how to create a business email, which covers other basic security measures too.
Attacks that try to get around 2FA
Two-factor authentication is very strong protection, but it isn't unbreakable. Scammers know it stops them, and they've come up with ways to get you to hand over the second factor yourself.
Phishing for the code. A fake login page asks not just for your password but also for the code from your app, and uses it straight away on the real site. Security keys and passkeys help here, because they refuse to work on the wrong address. We explain how to spot fake pages and emails in our article what is phishing.
"A call from your bank". Someone poses as a bank employee, mobile operator or support agent and asks you to read out the code you've "just received for verification". A real bank or company will never ask you for that code. If someone does, it's a scam.
Notification bombing. The attacker knows your password and fires off dozens of login attempts until, out of fatigue or by mistake, you tap "Approve". If you get a notification for a login you didn't make, deny it and change your password straight away, because it has already leaked.

SIM swapping. If your second factor is SMS, a scammer can move your number to their own SIM card. The protection is to use an app or a key instead of SMS, and to ask your mobile operator for an extra password before any SIM change.
If you suspect someone has already got into your website or admin area, see what to do in the first hour in our article what to do if your website has been hacked.
Common mistakes
- Two-factor protection on just one account. The bank is protected, but the email used to reset its password isn't.
- Lost backup codes. The account becomes inaccessible when you change phones.
- SMS where a better option exists. If the service supports an app or a key, use that.
- Reading the code out over the phone. No genuine company ever asks for it.
- Approving notifications out of habit. Every unexpected notification is a sign your password has leaked.
- A weak password with 2FA. Two-factor protection is no excuse for "123456". The password is still the first lock.
Frequently asked questions
What is two-factor authentication?
It's a way of logging in where, on top of your password, you have to prove who you are with a second, separate factor, most often a code from an app on your phone, a notification or a security key.
How secure is two-factor authentication?
It stops the vast majority of attacks with stolen passwords. Hardware keys and passkeys are the most secure, followed by authenticator apps. SMS is the weakest option, but still far better than a password alone.
Which is better: SMS or an authenticator app?
The app. The code is generated on the phone itself, doesn't travel over the mobile network and can't be intercepted by moving your number to another SIM.
What should I do if I lose my phone?
Log in with one of the backup codes you saved when you turned 2FA on, then set up two-factor authentication on your new phone. If you don't have backup codes, you'll have to go through each service's account recovery process.
Do I have to enter a code every time I log in?
Usually not. Most services can remember a trusted device and will only ask for a code when you log in from a new device or location.
Can two-factor authentication be bypassed?
Yes, most often by tricking you into handing over the code through a fake page or a phone call. So never share the code with anyone, and use security keys or passkeys for your most important accounts.
What's the difference between two-factor and two-step verification?
Two-factor authentication requires two factors of different kinds, such as a password and a phone. Two-step verification means two steps when you log in. In practice, both give the same protection when the second step is an app or a key.
Where should I turn on two-factor authentication first?
On your email, because that's where passwords for everything else get reset. Then on your bank, password manager, domain registrar, hosting and your website's admin area.
Conclusion
Two-factor authentication is the most effective protection you can turn on in a few minutes. It makes a stolen password useless and stops most attacks before they start. Start with your email, use an authenticator app instead of SMS, and use a security key or passkey for your most important accounts. Keep your backup codes away from your phone and never share a code with anyone.
Protection at server level too. Every WordPress hosting plan includes protection against attacks and malware scanning.


