If you’ve been told your website has been hacked or has malware you might be using these two terms interchangeably. Most people do. But understanding the actual difference matters when it comes to fixing the problem correctly, because the approach to each is different.
Table of Contents
ToggleThis article explains both terms clearly, where they overlap, how they differ, and crucially why addressing one without the other is how people end up getting hacked repeatedly.
MALWARE = What they installed or left behind after getting in
Most hacked websites contain malware. But not all malware is the result of a direct human hack. And a site can be hacked without visible malware at least for a while.
What Does 'Hacked' Mean?
What Hacking Actually Involves
| Type of Hack | How It Happens |
|---|---|
| Automated plugin exploit | Bot detects outdated plugin version, runs known exploit code, gains access. No human involved. |
| Brute force login | Bot hammers your /wp-login.php with username/password combinations until one works. |
| Credential stuffing | Your login credentials appear in a data breach. Attacker's tools try them on WordPress sites automatically. |
| Manual targeted hack | Human attacker specifically targets your site, typically only for high-value targets. |
| Supply chain hack | A trusted plugin or service you use is compromised; access arrives via your own update process. |
What Hackers Do After Getting In
After gaining access, an attacker typically does several things in rapid succession:
- Creates a backdoor to ensure persistent re-entry (so changing passwords won’t lock them out)
- Plants malware to achieve their monetisation goal (spam, redirects, data theft)
- Hides their tracks by modifying file timestamps and removing server logs if possible
- May add themselves as an admin user for direct access if needed
What Is Website Malware?
Malware malicious software is code that has been planted on your website to carry out an action that benefits the attacker. It is what the attacker installs on your site after gaining access.
Malware Is the Payload, the Hack Is the Delivery Mechanism
Think of it like this: hacking is breaking into a building. Malware is what the intruder leaves inside a bug, a camera, a lock that they now control. The break-in (hack) and what’s installed (malware) are two separate things, but they are related.
| Malware Type | What It Does for the Attacker |
|---|---|
| SEO spam / pharma hack | Uses your domain's Google authority to rank spam pages and earn affiliate commissions. |
| Redirect malware | Sends your visitors to affiliate spam stores, phishing pages, or adult sites. |
| Backdoor shell | Gives the attacker permanent server access for future malware re-planting. |
| Crypto-miner | Uses your server's CPU to mine cryptocurrency 24/7 at your expense. |
| Data harvester | Steals customer data, credit card information, credentials. |
| Drive-by download | Infects your visitors' devices when they load your pages. |
| Email spammer | Uses your server to send phishing and spam emails at scale. |
The Overlap: How They Interact
Step 2: BACKDOOR — Attacker plants a PHP shell for persistent re-entry
Step 3: MALWARE — Attacker installs redirect scripts and SEO spam injection
Step 4: DISCOVERY — Site owner notices redirects or a Google warning
Step 5 (DIY): Owner deletes malware (Step 3) but misses backdoor (Step 2)
Step 6: REINFECTION — Attacker re-enters via backdoor and replants malware within hours
Step 5 (CORRECT): Professional cleanup removes malware AND backdoor AND patches the vulnerability
Can a Website Have Malware Without Being Directly Hacked?
Scenario 1: Supply Chain Attack
Scenario 2: Shared Hosting Cross-Contamination
Can a Website Be Hacked Without Containing Malware?
Yes in the short term. An attacker who gains access may initially:
- Simply install a backdoor and wait holding access without deploying any visible malware yet
- Delete files or deface the site without planting persistent malware
- Steal database content (credentials, customer data) without leaving visible code behind
- Add themselves as an admin user and harvest data gradually
In these cases, a malware scanner may show the site as ‘clean’ while the attacker still has active access. This is why a clean scan result does not definitively mean a site has not been compromised.
Not Sure If You're Hacked, Infected With Malware, or Both?
admin audit and vulnerability review. Free scan available.
Why the Distinction Matters for Cleanup
| What Was Fixed | What Will Happen |
|---|---|
| Removed malware only | Attacker still has backdoor access. Malware returns within hours. |
| Removed backdoor only | Malware still active on site. Redirect/spam continues. Attacker creates new backdoor on next visit. |
| Changed passwords only | Backdoors bypass authentication. Attacker unaffected. |
| Patched vulnerability only | Existing malware and backdoors still active. Attacker already inside. |
| Removed malware + backdoors + patched vulnerability | Complete fix. Attacker has no access and no foothold. |
What a Complete Website Security Cleanup Covers
Malware Component
- Remove all malicious files and injected code (redirects, SEO spam, shells, miners)
- Clean all database injections in wp_options, wp_posts, wp_users
- Remove all spam pages indexed under your domain
- Submit Google blacklist removal requests
Hack Component
- Identify and patch the original vulnerability that was exploited
- Find and remove all backdoors (forensic-level file and database audit)
- Remove all unauthorised admin users and FTP accounts
- Revoke any active sessions
- Install a WAF to prevent future exploitation of similar vulnerabilities
- Review and harden file permissions
Practical Glossary: Security Terms Explained
| Term | Plain English Meaning |
|---|---|
| Hacked / Compromised | An unauthorised person has accessed your website's files, database, or admin panel. |
| Malware | Malicious code planted on your site to carry out an attack or generate revenue for the attacker. |
| Backdoor | A hidden access point that lets the attacker return even after passwords are changed. |
| Web shell / PHP shell | A type of backdoor file that executes any command the attacker sends via URL. |
| Vulnerability | A security flaw in a plugin, theme, or WordPress version that can be exploited to gain access. |
| Exploit | Code that takes advantage of a vulnerability to gain unauthorized access. |
| Infection | Synonym for a site that contains active malware. |
| Blacklisted | Google or another security vendor has added your domain to a list of dangerous sites. |
| SEO spam / pharma hack | Malware that injects spam pages or links to manipulate Google rankings. |
| Brute force | Attack that guesses passwords by trying thousands of combinations automatically. |
Hacked Site? Malware? Both? SEOHUB Has You Covered.
vulnerability patching in one service.
Frequently Asked Questions
Which is worse being hacked or having malware?
They’re not a competition — but an active backdoor (the hack component) is more dangerous than the malware itself because the backdoor is what makes reinfection possible. Malware is the symptom. The hack is the underlying condition.
My site shows as clean on Sucuri SiteCheck. Does that mean it's not hacked?
Not necessarily. External scanners can only see what they can access from the outside. They miss server-side backdoors, database injections with cloaking, and access that hasn’t yet been used to deploy visible malware. A clean external scan does not rule out a compromise.
How do I know if someone has been in my WordPress admin?
Check Settings > General for any changed URLs, Users > All Users for any unknown accounts, Plugins for any unfamiliar plugins, and review your server access logs (available in cPanel > Raw Access or Logs). If you find anything unexpected, treat the site as compromised until proven otherwise.