Skip to main content
Back to Blog
Cybersecurity 11 min read

My Small Business Website Was Hacked: What to Do in the First 24 Hours

A calm, step-by-step plan for small business owners whose website was hacked: confirm the hack, contain it, lock down accounts, restore a clean copy, close the hole, get Google's warning removed and handle customer data the right way.

Waqar Sharif Yar

Founder & CEO

Quick Takeaway

If your website was hacked, don't panic and don't start deleting files. Save a copy as evidence, take the site offline or into maintenance mode, change every password and turn on two-factor login, call your host, restore a clean backup, update or remove the plugin or account the attacker used, then request a review in Google Search Console.

Key takeaways

  • Confirm the hack first: check Search Console's Security Issues report, run a site: search for spam pages, and test your site on a phone you don't normally use.
  • Keep evidence before you clean. The FTC advises businesses not to destroy evidence, and you may need it for your host, insurer or police.
  • Restoring a backup without closing the entry point usually means getting hacked again. Google says unfixed sites are likely to be reinfected.
  • Google removes the "This site may be hacked" label only after you fix the whole site and request a review. Reviews can take a few days to a few weeks.
  • If customer personal data was exposed, breach notification rules depend on your state. Follow the FTC's breach response guide and talk to a lawyer.

A customer texts you a screenshot: your website is selling knockoff sneakers in Japanese, or it bounces them to a casino page, or Google shows "This site may be hacked" under your name. It feels like a break-in, and in a way it is. The good news is that most small business site hacks follow a few common patterns, and you can recover from them if you work in the right order.

This guide is that order. It is written for owners of small business sites, most often WordPress or another CMS on shared hosting. Follow it from the top, and don't skip the step about finding how the attacker got in. It is general information, not legal advice.

How do you know your website was actually hacked?

Some hacks are loud and some are hidden on purpose. Spam hacks often show their content only to Google or only to visitors arriving from search, so the site can look normal when you type the address yourself. Look for any of these signs:

  • Google shows "This site may be hacked" under your listing. Google says it shows this when it believes a hacker changed existing pages or added spam pages.
  • Search Console sends you a security email, or the Security Issues report lists problems such as content injection, URL injection, code injection or malware.
  • A Google search for site:yourdomain.com shows pages you never made, often in another language or about pills, gambling, replica goods or loans.
  • Visitors coming from Google or from a phone get redirected to another site, even though the site looks fine on your office computer.
  • New admin users you don't recognize, unfamiliar files on the server, or plugins you didn't install.
  • Your host suspends the account or warns you about malware, spam email or unusual traffic.

To check how Google sees a suspicious page, use the URL Inspection tool in Search Console. Google's guide on how to tell if your site was hacked explains this "cloaking" check in more detail. Our free website security checker can also show you quickly whether basics like HTTPS and security headers are in place, though no outside scan can see everything inside your server.

What should you do in the first hour?

The goal of the first hour is to stop the damage and keep the evidence. It is not yet to clean everything.

  1. Step 1: Don't delete anything yet

    Make a full copy of the site files and the database and store it offline. Google's hacked-site guidance says to save copies before you remove anything, and the FTC tells businesses not to destroy evidence. This copy helps you find the entry point later.

  2. Step 2: Take the site out of public view

    Put the site into maintenance mode, or ask your host to take it offline temporarily. A short outage is better than sending customers to malware or scam pages.

  3. Step 3: Write down what you see

    Note the time, screenshot spam pages and redirects, and save emails from Google or your host.

  4. Step 4: Call your hosting company

    Tell them the site is compromised and ask three things: can they scan the account, do they have clean backups from before the hack, and can they see logins or file changes in their logs. Many hosts have a dedicated security or abuse team.

  5. Step 5: Alert whoever else has access

    Your web designer, agency or IT person needs to know now, both to help and because their account could be how the attacker got in.

Which passwords should you change, and in what order?

Assume every password connected to the site is known to the attacker. Change them from a computer you trust, starting with the accounts that control everything else. Use a password manager so each password is long and unique.

Accounts to secure after a website hack, in priority order
PriorityAccountWhat to do
1Email account tied to your domain, host and registrarNew password, turn on two-factor login, check forwarding rules and recovery options for anything you didn't set
2Domain registrarNew password, two-factor login, confirm the DNS and contact details are unchanged
3Hosting control panel, SFTP and SSHNew passwords, remove unknown SSH keys and FTP users, turn off plain FTP if you still use it
4Website admin (WordPress or other CMS)Delete unknown admin users, reset every remaining user's password, turn on two-factor login
5Database passwordChange it with your host, then update the site's config file to match
6Connected servicesPayment gateway, email marketing, analytics, Search Console: review users and reset API keys stored on the site

CISA's guidance for small businesses puts it simply: any form of multi-factor authentication is better than none, and email accounts come first. An attacker who controls your email can reset every other password on this list.

Should you restore a backup or clean the site by hand?

If you have a backup from before the hack, restoring it is usually the fastest route. The hard part is knowing when the hack started, since attackers often get in weeks before anything visible happens. Pick a backup from before the earliest suspicious file change, login or spam page you found.

Restore from backup or clean in place
SituationBetter optionWhy
Clean backup from before the hack, few content changes sinceRestore the backupFastest and most reliable; re-add the few posts or products you lost
Backups exist but you don't know when the hack startedRestore, then scan and compare with the evidence copyOld backups can contain the same backdoor
No usable backupClean in place, or hire a cleanup serviceReinstall core files, themes and plugins from official sources, then review custom code and the database
Online store or site that collected customer dataGet professional helpYou may need to know exactly what was accessed, which affects your legal duties

Whichever route you take, Google's hacked-site guidance recommends reinstalling the core files of your CMS plus every theme and plugin from their official sources, not from copies on your server. Also check the .htaccess file and server config for redirect rules you didn't add, since spam hacks often hide there.

How did the attacker get in?

This is the step people skip, and it is why sites get hacked twice in the same month. Google warns that if you don't fix the weakness that let the hack happen, your site is likely to be reinfected. Google's list of the top ways sites get hacked matches what small businesses run into:

  • Outdated plugins, themes or CMS core. Known security holes in old versions get scanned for automatically, across millions of sites.
  • Abandoned or "nulled" plugins. Google warns that attackers add malicious code to free copies of paid plugins and themes. Remove anything you didn't buy from the real developer.
  • Weak or reused passwords. Attackers guess or reuse leaked passwords, especially on admin and FTP accounts with no two-factor login.
  • Old accounts. A former employee, an old agency login or a test user nobody deleted.

Ask your host for access logs around the time of the first suspicious change, and look at which plugin, file or login was involved. If you can't find the cause, treat everything as suspect: update every component, remove what you don't use, and keep two-factor login on every admin account.

How do you get Google's hacked warning removed?

Google doesn't remove the warning on its own. According to Google Search Help, the owner has to fix the site and request a review, and Google removes the label after it confirms the fix.

  1. Step 1: Verify the site in Search Console

    If you haven't already, add and verify your domain in Google Search Console. This is also where Google sends future security alerts.

  2. Step 2: Open the Security Issues report

    Each issue lists sample URLs. Fix the problem across the whole site, not only on the samples.

  3. Step 3: Remove the spam pages

    Spam URLs should return a 404 or 410 error once deleted. Our guide to Google not indexing your pages explains how indexing works.

  4. Step 4: Request a review

    Select Request Review and explain the exact issue, the steps you took and the result, for example: "Spam pages were added through an outdated plugin. We removed the plugin, restored a clean backup from [date], reset all passwords and turned on two-factor login."

  5. Step 5: Wait and don't resubmit

    Google says reviews for hacked content can take from a few days to a few weeks. Sending another request while one is pending can make the review take longer.

While you wait

If the hack also sent spam email from your domain, your email may land in spam for a while. Our guide to why your emails are going to spam and our explainer on SPF, DKIM and DMARC cover how to check and fix that.

Do you have to tell customers?

It depends on what the attacker could reach. A spam-page hack on a brochure site with no customer data is a different situation from a hacked online store or a site with a client login. If names together with things like card numbers, Social Security numbers, account logins or health information may have been exposed, you may have legal notice duties.

  • State law decides most of it. Breach notification rules vary by state, including what counts as personal information and how fast you must act. The FTC's data breach response guide tells businesses to check the laws that apply in their state.
  • Health data has its own rules. The FTC's Health Breach Notification Rule or HHS's HIPAA rules may apply.
  • Tell law enforcement. The FTC suggests contacting local police, and you can report incidents to CISA at cisa.gov/report.
  • When you notify people, be specific. Say what happened, what information was involved, what you are doing and what they can do. The FTC suggests pointing them to IdentityTheft.gov.

General information, not legal advice

If customer data may have been exposed, talk to a lawyer before you send notices. Breach laws differ by state, and timing and wording matter. Check whether your business insurance includes cyber coverage, since many policies require prompt notice.

How do you stop it from happening again?

Most of the prevention list is boring maintenance, and that is the point. Run through this once now, then put a monthly reminder on the calendar.

  • Turn on automatic updates for your CMS, themes and plugins where your host or CMS supports it, and check monthly that they ran.
  • Delete plugins and themes you don't use. Deactivated code can still be exploited.
  • Turn on two-factor login for the CMS, hosting panel, registrar and email.
  • Give each person their own login with the lowest role they need, and remove access the day someone leaves.
  • Keep automatic daily backups stored away from your hosting account, and test a restore a few times a year, as CISA recommends.
  • Keep Search Console verified so Google can email you about security issues.
  • Write down who to call (host, developer, insurer) and where the backups are, so the next incident starts with a plan.

Rechecking every few months with the free website security checker catches missing basics such as an expired SSL certificate or missing security headers. If you're rebuilding after a bad hack, our guide on redesigning a website without losing SEO helps you keep your rankings during the move.

Can I just restore a backup and move on?

Restoring is often the right first move, but on its own it rarely ends the problem. If the plugin, password or account the attacker used is still there, they can get back in. Restore, then update everything, reset passwords and remove unused plugins.

How long does it take for Google to remove the "This site may be hacked" warning?

Google says reviews for hacked content take from a few days to a few weeks after you request one in the Security Issues report. The warning goes away once Google confirms the site is clean.

Will a hack hurt my Google rankings?

It can. Spam pages compete with your real pages, and the warning label discourages clicks. Rankings usually recover after you clean the site and Google recrawls it, but don't wait: the longer spam stays up, the more of it Google indexes.

Do I need to report a website hack to the police?

For a spam hack with no data involved, it's usually optional. If customer data may have been taken, the FTC advises contacting law enforcement, and you can report incidents to CISA. Your lawyer and insurer can tell you what your state and policy require.

A hacked website is stressful, but it is fixable when you work in order: contain, lock down, restore, close the hole, then ask Google to look again. If you'd rather have someone handle the cleanup and hardening with you, our cybersecurity team can help.

Add WikiAI as a preferred source on Google(opens Google in a new tab)

Free: 100 AI Automation Ideas for Small Business

A practical checklist of 100 tasks you can automate, grouped by department. Enter your email for the printable version and occasional tips.

No spam. Unsubscribe any time by replying “unsubscribe”. See our privacy notice.

Sources and further reading

Services related to this article

Cybersecurity 9 min read

Password Managers for Small Business Teams: Choose and Roll Out

Why shared password spreadsheets fail, what a business password manager needs, a price comparison of 1Password, Bitwarden, Dashlane and Keeper business plans, a four-week rollout plan and an offboarding checklist.

Cybersecurity 10 min read

How to Back Up Your Small Business Data: A Simple 3-2-1 Plan

What to back up, how the 3-2-1 rule works, why cloud sync is not a backup, what Google Workspace and Microsoft 365 actually keep after deletion, a backup schedule, and how to test a restore before you need one.

Need a Hand?

Need HelpImplementing This?

Reading about it is one thing, shipping it is another. Book a free strategy call and we will help you put it into practice in your business.

  • Free 30-minute strategy call
  • No commitment required
  • Reply by email or WhatsApp