Skip to content
PK Hosting

WordPress Site Hacked in Pakistan? A First-Hour Recovery Checklist (2026)

PK Hosting TeamDate: 9 min read

Developer reviewing website security alerts on a laptop screen

You opened your shop site on mobile and landed on a gambling page. Google Search shows a red Deceptive site ahead interstitial. A customer forwarded a spam email that claims to be from your domain. Or your host sent a short note: the account is suspended until you remove malicious files. However it surfaced, a WordPress site hacked feels urgent β€” and the wrong first move (panic-restore, or handing passwords to a random "cleanup" seller on WhatsApp) often makes it worse.

This guide is a practical, time-ordered checklist for Pakistani small-business and blog owners on WordPress: contain damage, preserve what investigators need, close the doors the attacker used, remove common malware hiding places, then ask Google to trust you again. It assumes you have hosting with file and database access β€” through the PK Hosting client dashboard, SFTP, or the hosting control panel (Hestia on our shared stack). It is not a guarantee that every infection is visible in an hour; some need a developer. It is the sequence that stops reinfection and buys you a sane next step.

Signs your WordPress site may be compromised

Not every glitch is malware. These patterns are worth treating seriously:

  • Unexpected redirects β€” especially on mobile only, or only when you are logged out (attackers often hide from administrators).
  • New pages you did not publish β€” pharma, casino, or SEO spam in languages you do not use.
  • Unknown administrator accounts in Users β†’ All Users, or admin emails you do not recognise.
  • Plugins or themes you never installed, sometimes with plausible names.
  • Modified core files β€” unexpected changes under wp-admin or wp-includes if your host or a integrity tool reports them.
  • PHP files inside uploads β€” legitimate media folders should not contain executable .php (except rare, documented exceptions).
  • Browser or Google Safe Browsing warnings on a site that looked fine yesterday.
  • Email blacklisting or spam complaints when your site sends mail through PHP forms or compromised accounts.
  • Hosting suspension notice citing malware, phishing, or outbound abuse.

If several of these appear together, assume compromise until you prove otherwise.

What not to do in the first hour

  • Do not restore an old "clean" backup and call it done. Backups are essential β€” but if the hole is an outdated plugin, a leaked password, or a re-uploaded backdoor, the site will re-hack within days. Restore only after you understand the entry path or you have rebuilt from known-good core, theme and plugin packages.
  • Do not pay strangers who DM you "WordPress malware removal Pakistan" and ask for wp-admin and hosting passwords. Use people you can verify, or your host's official support channel. PK Hosting will never ask for your password in an unsolicited chat.
  • Do not delete everything blindly. You need a snapshot of the compromised state if you later need to trace which theme, plugin or upload introduced the code.
  • Do not leave the site publicly serving redirects while you "fix it later tonight." Contain first β€” even a maintenance page is better than spreading malware to visitors.

First-hour recovery checklist (in order)

Work top to bottom. Skipping containment or password resets is how cleaned sites get re-owned the same evening.

1. Contain β€” stop the bleeding

Goal: visitors and Google bots stop hitting malicious responses.

  • Enable maintenance mode from a reputable plugin you already trust, or temporarily replace the public site with a static holding page β€” only if you know how to do so without breaking access you need.
  • If your host suspended the account, read the notice carefully. Suspension is harsh but it limits damage; reply through official support with the domain name and a short description.
  • On PK Hosting, sign in at the client login, open the hosting service, and note the document root path shown there before you edit files.

2. Back up the current state (yes, the infected one)

Download a full copy of public_html (or your domain folder) and export the database from phpMyAdmin or the panel's database tools. Label the archive with today's date and "incident". This is your evidence bundle β€” not something you should restore to production unchanged, but something a developer or support engineer may need to compare against a clean tree.

If your plan includes automated backups, note what retention allows β€” see the backup policy for how copies and restore requests work. Do not assume a backup from three weeks ago is still listed until you check the dashboard.

3. Change every password that could have leaked

Assume credentials are burned. Rotate all of these, using a password manager if you can:

  • PK Hosting client dashboard password (and enable two-factor authentication there if you have not).
  • Hosting control panel (Hestia) password for the hosting user β€” distinct from the client dashboard login.
  • SFTP/FTP and any SSH keys; revoke keys you do not recognise.
  • Database user password β€” update in the panel and in wp-config.php so WordPress can still connect.
  • Every WordPress user with Administrator role β€” force new passwords; remove users you did not create.
  • Email mailboxes on the same domain if the site sends mail β€” compromised sites often abuse SMTP or forms.

Do this before you spend an hour deleting files, or the attacker may log back in while you work.

4. Remove unknown administrators and audit roles

In WordPress admin β†’ Users, delete or demote accounts you do not recognise. Check hidden admin emails β€” attackers sometimes create adminbackup-style users. Keep at least one admin you control; if you cannot access wp-admin at all, reset a password via the database or your host's tools, then log in immediately over HTTPS. Our SSL guide explains why admin over plain HTTP is risky on shared networks.

5. Inventory plugins, themes and suspicious files

  • Deactivate and delete plugins you do not use. Remove nulled or pirated themes β€” they are a common infection source.
  • Compare your plugin list to what you actually installed; remove anything unfamiliar.
  • Search wp-content/uploads for .php files. Media uploads should be images, PDFs, and similar β€” not PHP scripts. Quarantine anything suspicious (move outside the web root), do not "fix" obfuscated code in place unless you know what you are editing.
  • Check recently modified files in the theme directory β€” especially functions.php and footer templates β€” for injected scripts or base64 blobs.

Platform-level malware response on WordPress hosting covers the hosting stack we operate; cleaning arbitrary PHP injected into your uploads or a vulnerable plugin is still site-owner or developer work unless you have agreed a separate service. When in doubt, open a ticket from your account or use the contact page with the domain and what you already tried.

6. Reinstall WordPress core and trusted plugins from clean sources

Download fresh WordPress from wordpress.org and replace wp-admin and wp-includes (not wp-content) with the clean copy. Reinstall plugins you still need from the official directory or the vendor's site β€” upload a new ZIP rather than trusting existing folders. Update the active theme from its legitimate source if updates are available.

After updates, visit the site logged out and logged in, and hit key pages (home, contact, checkout if you run WooCommerce). Speed and stability still matter for trust β€” see speeding up WordPress once the site is clean, not as a substitute for removal.

7. Rotate WordPress security keys (salts) in wp-config.php

WordPress session cookies depend on the AUTH_KEY, SECURE_AUTH_KEY, and related constants in wp-config.php. Generate a new set from the WordPress.org secret-key service, paste them into wp-config.php, and save. That logs everyone out β€” including any attacker still using a stolen cookie β€” and is worth the brief inconvenience.

8. Google Search Console and Safe Browsing

If Google flagged the site, fixing files is only half the job.

  • Verify the property in Google Search Console if you have not already.
  • Open Security & Manual Actions (or the security issues report) and read what Google saw β€” often injected URLs or social engineering content.
  • After you believe the site is clean, use Request Review and describe what you removed and hardened. Reviews take time; keep the site clean while you wait.

Do not spam repeated review requests on the same unchanged site β€” that slows trust recovery.

9. Harden so it does not happen again

  • Update WordPress core, plugins and themes on a schedule β€” neglected updates are the most common reason small-business sites in Pakistan get hacked.
  • Remove unused plugins and themes instead of leaving them "disabled but installed".
  • Use strong, unique passwords and two-factor authentication on administrator accounts (a reputable 2FA plugin or your security plugin's feature).
  • Least privilege β€” give shop staff Editor or Shop Manager roles, not Administrator, unless they truly need full control.
  • Regular off-site backups you have tested restoring β€” not only copies on the same server as the site.
  • HTTPS everywhere β€” eligible PK Hosting plans include a free DV certificate once DNS is correct; keep admin and checkout on HTTPS only.

If the site outgrew shared resources while you were fighting malware, read what matters for WordPress hosting in Pakistan before you upgrade tiers. Moving hosts without cleaning first just transports the infection β€” our migration guide assumes a site you are confident is safe to copy.

When to call for help

Bring in a developer or host support when wp-admin is inaccessible, the database will not export, reinfection returns within hours, or you find encrypted ransomware-style messages. Gather: the suspension email (if any), a list of unknown plugins, and whether you recently installed a nulled theme or left an old demo site online.

PK Hosting customers can email [email protected], call (042) 35692952, or open a ticket after signing in. Include the domain and whether Google still shows a warning β€” not your passwords in the first message.

Soft next step

Once the site is stable, compare WordPress hosting plans or broader shared hosting if you need a fresh environment, and use checkout when you know the tier. First-time shared hosting orders sometimes qualify for promo code WELCOME10 on eligible hosting at checkout β€” it does not replace cleaning a compromised site. If you are rebuilding on the same account, finish this checklist first, then worry about coupons and plan upgrades.

Frequently asked questions

My WordPress site was hacked β€” should I restore yesterday's backup?

Not as the only step. Restore helps if you know exactly when the site was still clean and you have closed the vulnerability (updated plugin, removed backdoor, new passwords). Otherwise the same attacker or file often returns within days. Back up the infected state first, then clean or rebuild from known-good core and plugins.

Where do WordPress hackers hide malware?

Common places include unused plugins, modified theme files (especially functions.php), wp-content/uploads with unexpected PHP files, and newly created administrator accounts. Core directories wp-admin and wp-includes are also replaced in some attacks β€” which is why reinstalling core from wordpress.org after cleanup is standard advice.

How do I fix a Google deceptive site warning on my Pakistani business site?

Remove the malicious content and close the entry point, verify the property in Google Search Console, confirm Security issues shows clean, then submit a review request with a short note on what you fixed. Warnings can persist for a while after the site is clean; avoid requesting review repeatedly without changes.

Does PK Hosting remove WordPress malware for free?

WordPress-branded plans describe platform malware response on the hosting stack β€” not unlimited custom cleanup of every plugin or uploaded file on your site. Serious infections often need your developer or a scoped security service. Contact support through your account or the contact page with the domain name so staff can tell you what applies to your plan.

What passwords should I change after a hacked website fix?

Change the client dashboard login, hosting control panel user, SFTP/FTP, database user (and wp-config.php to match), every WordPress administrator, and any compromised email mailbox used to send site mail. Rotate WordPress salts in wp-config.php to invalidate existing login cookies.

Keep learning

Related hosting guides

Browse all guides
We treat your site as ours

Let’s get your website online today

Compare plans, complete checkout, view invoices and manage payments on pkhosting.com.