Hasibul Hasan Sakib Logo
Hasibul Hasan Sakib Building What's Next •
2026-10-30 • 8 min read

How to Fix the Japanese Keyword Hack in WordPress (2026 Guide)

A first-hand guide to removing the Japanese keyword hack from WordPress: find the backdoor, clean and harden the site, and make Google drop the spam pages with 410s and a spam sitemap.

Hasibul Hasan Sakib
Hasibul Hasan Sakib AI Automation, WordPress & WooCommerce Specialist
How to Fix the Japanese Keyword Hack in WordPress (2026 Guide)

Short answer: The Japanese keyword hack is malware that creates thousands of fake Japanese shop pages under your domain, usually hidden from you and shown only to Google. Fixing it takes two separate jobs: remove the backdoor that creates the pages, then make Google drop the spam URLs (410 responses, a spam sitemap and monitoring). Cleaning the files alone does not clean your search results.

I had this hack on my own website in 2026. This guide is the exact process I used, with the real numbers.

What is the Japanese keyword hack?

Attackers get into a WordPress site, usually through an outdated plugin, a weak password or a vulnerable server, and plant a small backdoor. The backdoor generates pages in Japanese that advertise counterfeit goods or shops, at URLs that look like random words and letters (on my site they followed a pattern like /word/word/random12chars.html).

The clever part is cloaking: the hack often shows the spam only to Google’s crawler. When you open your site in a browser, everything looks normal.

How do I know if my WordPress site has it?

  • Google search: search site:yourdomain.com. Japanese titles you never wrote are the clearest sign.
  • Search Console → Performance: Japanese search queries or clicks from Japan you can’t explain.
  • Search Console → Pages: a sudden jump in indexed or “crawled, not indexed” pages. On my site the report showed 132,148 indexed and 619,739 not indexed pages, almost all of them spam.
  • URL Inspection → Test live URL: inspect one of the strange URLs. If Google sees a page that you can’t, the site is cloaking.

Step 1: Back up and lock down

  1. Take a full backup of files and database before you change anything, and keep it off the server. You may need it to compare files later.
  2. Change every password: hosting, SFTP/SSH, database, and all WordPress administrators.
  3. Check the WordPress user list and remove any administrator you don’t recognise.
  4. Generate new WordPress security keys (salts) so every existing login session ends.

Step 2: Find the backdoor

This is the part most cleanups miss. The pages are only the symptom; the backdoor keeps making them. On my site the backdoor was a PHP file disguised as a font (.ttf) inside the WordPress core folders, plus an encoded payload hidden in a fake image file, and copies of small loader files in strange self-nested folders such as images/images/.

Where to look:

  • Core files: run wp core verify-checksums (WP-CLI). Any modified or extra core file is suspicious.
  • PHP in uploads: wp-content/uploads should contain no PHP files at all.
  • Files that pretend to be something else: PHP code inside .ttf, .jpg, .png or .ico files.
  • Recently changed files around the date the spam started, and folders nested inside themselves.
  • Must-use plugins, cron jobs and .htaccess rules you didn’t add.
  • The database: unknown options, injected scripts in posts, and extra administrator accounts.

Move suspicious files into a quarantine folder outside the website instead of deleting them straight away, so you can restore anything you removed by mistake.

Step 3: Remove and harden

  • Replace WordPress core with a fresh copy and reinstall plugins and themes from their official sources.
  • Update everything, including PHP itself.
  • Block PHP execution in the uploads folder.
  • Disable the built-in file editor (DISALLOW_FILE_EDIT).
  • Remove plugins and themes you don’t use.

Step 4: Make Google forget the spam pages

After the cleanup, Google still remembers thousands of spam URLs. On my site the spam kept showing in search for weeks, and while it did, my real pages got almost no visibility. What moved it:

  1. Return 410 Gone for the spam URL pattern, not 404. I added one server rule that matches the pattern. A 410 tells Google the page was removed on purpose.
  2. Submit a sitemap of the spam URLs. I listed the 334 spam URLs Google had already seen, so it would re-crawl them sooner and see the 410. Remove that sitemap once the URLs have dropped out.
  3. Don’t block the spam URLs in robots.txt. If Google can’t crawl them, it can’t see that they are gone.
  4. Push your real pages: a clean sitemap, IndexNow, and “Request indexing” in Search Console for your most important pages.
  5. Use the Removals tool only for emergencies. It hides URLs for about six months; it doesn’t remove them permanently.

Step 5: Keep watching

A scan that says “clean” today doesn’t mean the site stays clean. I now run a daily file scan and a check that compares what Googlebot sees with what a normal visitor sees, because cloaking is exactly what this hack relies on. I turned that monitoring into a free plugin, Index Sentinel.

How long does it take Google to drop the spam?

Weeks, not days. On my site Google was showing 72 spam pages a week in August. By the second week of October it was down to 8, and that same week my real pages were shown 55 times. Small numbers, but the line finally went the right way.

What I’d do first if you have it today

  • Back up, then change every password and remove unknown admins.
  • Find the backdoor before deleting pages, or they will come back.
  • Serve 410 for the spam pattern and keep it crawlable.
  • Monitor for cloaking every day for at least a month.

If you’d rather have it handled, this is exactly what my Japanese keyword hack fix service covers, from backdoor removal to getting the spam out of Google. If you are also checking your server’s PHP version this month, see the PHP2Shell 10-minute check.

Sources

Frequently Asked Questions

Why can't I see the Japanese pages on my own site?
The hack usually cloaks: it shows the spam only to Google's crawler. Use Search Console's URL Inspection with "Test live URL" to see what Google sees.

Is deleting the spam pages enough?
No. The pages are generated by a backdoor. If you delete pages but leave the backdoor, new spam pages appear again.

Should the spam URLs return 404 or 410?
Use 410 Gone for the spam URL pattern and keep those URLs crawlable, so Google can see they were removed on purpose.

How long until Google stops showing the spam?
Usually several weeks. On my site the spam shown in Google went from 72 pages a week in August to 8 by the second week of October.

Hasibul Hasan Sakib

Written by Hasibul Hasan Sakib

AI Automation, WordPress & WooCommerce Specialist

I build and secure WordPress and WooCommerce sites for businesses in the US, UK and Europe, and add AI assistants that answer from a company's own content. I cleaned my own site after a Japanese SEO-spam hack and built the free Index Sentinel plugin from that experience.

Chat on WhatsApp