Brute Force Explained: How Attackers Guess Passwords

Brute force explained in plain terms means understanding the simplest attack in computing: trying every possible password, one after another, until the right one is found. The central question is how a password that feels secret can fall to an attacker who knows nothing about its owner, and the short answer is that the attacker does not need to be clever, only fast, because a computer can try millions of combinations in the time it takes a person to type one.

Most people never see a brute-force attack, because it happens quietly on a distant server. The login page looks the same, the owner notices nothing, and the only sign is a sudden flood of failed login attempts in a log file nobody reads. By the time the account is breached, the attack is already over.

The defence against it is also simple, and it is worth understanding, because the same mathematics protects every account a person owns. This article explains what a brute-force attack is, how it works, and what stops it.

Key takeaways

  • A brute-force attack tries every possible password until one works.
  • Short and simple passwords fall in seconds; long ones can take centuries.
  • Attackers start with common passwords and dictionaries before trying everything.
  • Lockouts, delays, and extra checks are what slow the attack down.
  • A password manager and a second factor are the strongest defences.

What a brute-force attack is

A brute-force attack is an attempt to gain access by systematically trying every possible value of a secret, usually a password or a PIN, until the correct one is found. The attacker needs no knowledge of the victim, no leaked data, and no clever trick, only a list of guesses and enough computing power to work through them.

The mathematics is unforgiving. A four-digit PIN has only ten thousand combinations, and a computer can try them all in less than a second. A short password of lowercase letters has far more, but still few enough that a fast machine can exhaust them in minutes. Every character added to the password multiplies the number of combinations, which is why length is the single most important property a password has.

Real attackers rarely start with pure brute force. They begin with a dictionary of the most common passwords, the names, dates, and words people actually choose, and they try variations of those first, adding numbers, capitals, and symbols in the ways people typically do. Only when the easy guesses fail do they fall back to trying every combination, and most accounts fall long before that point. Our guide to password managers explains the tool that creates and stores long, random passwords, and our guide to cryptography explains the mathematics that protects a password once it is stored.

How a brute-force attack works

An online attack works against the live login page. The attacker sends guesses one at a time, and the server says yes or no to each, which is slow, because the network and the server limit how fast guesses can arrive. A website that allows only a few attempts per minute can make an online attack take years, which is why rate limiting is the first defence every service should have.

An offline attack is far more dangerous. If the attacker steals the file of password hashes, the scrambled versions of passwords that a service stores, they can try guesses on their own machines, with no server to slow them down. A single graphics card can try billions of hashes a second, and a room full of them can work through enormous lists in days. The only thing protecting the passwords then is their length and the strength of the hashing.

Password hashing is what makes offline attacks hard. A good hash is deliberately slow, taking a noticeable fraction of a second to compute, which barely matters to a person logging in once, but multiplies the attacker’s work by millions. A weak hash, or a password stored with no hashing at all, lets the attacker try guesses at full hardware speed, and the passwords fall quickly.

Credential stuffing is a related attack that skips guessing entirely. The attacker takes username and password pairs leaked from one breach and tries them on other sites, betting that people reuse the same password. It works depressingly often, and it is the reason security advice insists that every account should have a different password.

Distributed attacks spread the work across many machines, often a botnet of compromised computers, so that no single address makes enough attempts to trigger a block. Each machine tries a few passwords, the total adds up, and the target sees guesses arriving from thousands of different places at once.

A laptop on a dark desk with its screen showing a glowing green login screen with a warning about failed attempts
A laptop showing a glowing green login screen with a warning about failed attempts shows the visible sign of a brute-force attack: many guesses, one after another.

Comparing brute force with smarter attacks

Brute force and smarter attacks both aim at the same secret, but they spend their effort differently. One tries everything, while the other uses knowledge about people to guess the likely answers first.

The table below sets out the main contrasts between the two approaches.

Aspect Brute force Dictionary attack
Guesses Every combination, in order Common passwords and words first
Speed needed Very high, to cover the space Low, the list is short
Works against Any password, given time Only predictable passwords
Time to succeed Seconds to centuries Seconds to minutes
Best defence Long, random passwords Unpredictable passwords

The practical result is that the two attacks are really one attack with two phases: the dictionary phase, which catches the careless quickly, and the brute-force phase, which catches the rest slowly. A long, random password defeats both, because it is neither in any dictionary nor reachable in reasonable time.

Where brute-force attacks happen

Login pages are the most common target. Any website with a sign-in form is probed constantly by automated tools trying common passwords against lists of usernames, and the owners rarely notice, because the attempts are spread across many addresses and look like ordinary traffic.

Remote access services are a favourite target, because they are exposed to the whole internet. Servers offering remote login, file transfer, or database access are attacked around the clock, and a weak password on such a service can hand an attacker a whole machine in minutes.

Encrypted files are attacked offline. A stolen laptop, a leaked document, or a captured backup can be attacked at full speed with no server to slow the guesses, and the only protection is the strength of the password that locked the file.

Wireless networks are attacked by capturing the handshake, the brief exchange that happens when a device joins, and then guessing the network password offline. A short Wi-Fi password falls quickly, which is why the password on a home router matters more than most people think.

Payment cards and PINs are attacked in a limited form. A four-digit PIN has only ten thousand combinations, so the defence is not the size of the space but the lockout: a card that blocks after three wrong guesses cannot be brute forced, no matter how small the space is.

Strengths and limits

The greatest strength of a brute-force attack, from the attacker’s view, is that it always works eventually. Given unlimited time, every password will be found, and no amount of cleverness in choosing the password can change that. The attack needs no information about the victim and no vulnerability in the software.

It is also a strength that the attack is simple to automate. A script and a list of guesses are all it takes, and the tools are freely available, so an attacker with no skill at all can run one. The barrier to trying is essentially zero.

The limits are real, though, and they are entirely about time. A long password pushes the attack beyond any practical horizon, a slow hash multiplies the work, and a service that limits attempts or requires a second factor makes the attack pointless. Brute force is powerful only against defences that let it run freely.

Brute-force defence checklist

  • Use long, random passwords, and let a password manager create them.
  • Never reuse a password between two accounts.
  • Turn on a second factor wherever it is offered.
  • Limit login attempts and add delays after failures.
  • Lock accounts temporarily after too many wrong guesses.
  • Store passwords as slow hashes, never as plain text.
  • Watch login logs for sudden bursts of failed attempts.
  • Block addresses that try many accounts with few guesses each.
  • Change any password that appears in a known breach.

Frequently asked questions

What is a brute-force attack in simple terms?

A brute-force attack tries every possible password, one after another, until the right one is found. It needs no cleverness, only speed, and it works because computers can try millions of guesses quickly.

How long does a brute-force attack take?

It depends on the password. A short, simple password can fall in seconds, while a long, random one can take centuries, even with powerful hardware. Length is the decisive factor.

What is a dictionary attack?

A dictionary attack tries common passwords, words, and names first, before falling back to trying every combination. It succeeds quickly against predictable passwords, which is why common choices are so dangerous.

Can a brute-force attack be stopped?

Yes, in practice. Limiting login attempts, adding delays, requiring a second factor, and storing passwords as slow hashes all make the attack too slow or too costly to succeed.

What is credential stuffing?

Credential stuffing takes username and password pairs leaked from one breach and tries them on other sites. It works because people reuse passwords, and it is stopped by using a different password for every account.

Does a longer password really help?

Enormously. Every character added multiplies the number of possible passwords, so a password of fourteen random characters is vastly harder to guess than one of eight. Length matters more than complexity.

The bottom line

Brute force explained in one line is this: an attack that guesses a password by trying every possibility, defeated only by making the possibilities too many to try.

It is the simplest attack in security, and the oldest, and it still works wherever passwords are short, reused, or unprotected. The defence is equally simple, and it has not changed in decades: long, unique passwords, a second factor, and a service that refuses to let guesses arrive too fast.

This article is general information about how brute-force attacks work, not advice about securing a particular account or system.

Latest articles

Scroll to Top