There are some things that you really don’t want to see when you visit your website. Right at the top of that list is an internet security alert red screen warning courtesy of the Google Chrome browser. “The site ahead contains harmful programs” is not a welcoming introduction to your website.
The Google Safe Browsing warning is telling potential visitors not to visit your site because there is a dangerous element present.
There are several different warning messages that may be displayed:
- The site ahead contains malware
- Deceptive site ahead
- The site ahead contains harmful programs
- This page is trying to load scripts from unauthenticated sources
- Continue to [site name]?
Those all mean different things, and some are more serious than others. But obviously you don’t want a warning message of any kind being inserted between you and your visitors.
In this tutorial, I’m going to go over a few ways to fix and prevent “The site ahead contains harmful programs,” or “The site ahead contains malware” Google Chrome red screen warning.
Why Does This Screen Appear?
The warning screens are displayed by the Chrome browser when Google has crawled the site and found something in the content that they consider harmful. Elements that trigger the Google Chrome warnings for a WordPress site vary, but can include:
- Malware installed on the website.
- Links to sites that distribute or are infected with malware.
- Certain very outdated content management systems.
- Plugins or themes that have been compromised or are open to compromise.
Even spam in your comments could link to questionable sources and cause a warning. Luckily, it’s easy to protect your WordPress comment section from spam.
You’ll need to do a bit of troubleshooting to discover why your site has been tagged with a warning screen.
Checking Your Site in the Google Search Console
The first thing you should do is check with Google to see why there is a problem. To do so, click the “Security issues” link in the Google Search Console.
If no security issues are present (as shown above), file a report for an incorrect phishing warning. You can do this by visiting Google’s “Report Incorrect Phishing Warning” page.
Complete the form and click the “Submit Report” button.
If the Google Search Console does indicate a problem with your site, click the “More Information,” “Details,” or “Why Was This Website Blocked” link for more information on the cause of the problem.
You can also use the Google Safe Browsing site status page to see exactly where the malicious content is located on your site. Go to:
Change “ggexample.com” above to your domain name, of course.
Google Search Console
The new Google Search Console will break down the issues it found with your site and why it is being flagged. This often appears as a red warning on your site in the console system.
From there, you can click the “Details” link. Google will then give you a brief breakdown of the error.
For instance, Google will tell you where malware is located as it was detected on your site including any subfolders in your directory.
Once you’ve cleaned the files and have fixed the issue, you can submit it for validation in Search Console. The validation process can take a couple of days to complete. And if Google doesn’t find a problem, your site is restored and the “site contains harmful programs” error is removed.
Malware Scanning and Removal
Deleting the malicious content from the specific locations that Google provides is a good start, but that report may not include everything. You’ll want to do a thorough scan and remove all malicious code or software, wherever it’s hiding.
To do that you can use a security scanning plugin or system.
There are many security plugins available when it comes to locking down WordPress. Here are three of my favorites.
Wordfence is a free plugin that comes with a great selection of tools. It will perform regular threat updates, file scanning, and provides a powerful firewall. This is one of the most popular plugins for security with more than two million active installs.
All In One WP Security & Firewall
The All In One WP Security & Firewall plugin is exactly what it sounds like. It includes file system security, blacklist checking, login safety, and backup options. It’s a flexible system that does a great job at protecting your site, and your visitors, from malware.
Another popular plugin for malware scanning is Sucuri Security. It does remote scanning, file integrity monitoring, and includes a hardening system for website security. However, a lot of its more advanced options are only available in the premium version of the software. But if you deal with security problems on an ongoing basis, Sucuri may be well worth the investment.
Check Your Links
Even if your website is safe, it can be flagged for having links to malware-infected sites. If you link to a site that is known to contain malware, your site can be tagged with a “The site ahead contains harmful programs” warning. Since all search engines have safety and security rules to uphold, your site will be guilty by association if you link to websites that are seen as malicious or dangerous.
If you cannot find a source of malware or other threats on your website, you may have been flagged due to a link. So you’ll need to find the links that could be causing the warning for your site.
Sometimes serving ads can cause problems as well. For example, displaying an affiliate banner to a known offender can cause your site to be flagged.
Always check the source of links. Only use safe, quality links when linking to other websites, displaying ads, or selling products.
Some security plugins or systems will do the checking for you automatically. But it’s still a good idea to make sure you’re only adding the best links to your site. Doing so will also help with search engine optimization and demonstrate your website’s relevance and authority.
Deceptive Site Ahead Fix
The “Deceptive site ahead” warning is a little different, so let’s talk about it separately. It can be triggered by malware but is more likely to be triggered by misconfiguration. Most commonly:
- You have a self-signed SSL certificate or you have not installed SSL Certificate properly.
- You do have an SSL certificate installed but you are not redirecting HTTP users to HTTPS.
- There is mixed content on your website. You’ll run into this most often after converting a site to use HTTPS. If script or image links to HTTP URLs remain, that’s mixed content that needs to be fixed.
Removing the Google Warning
After cleaning up your site, you have to let Google know it’s safe. To do that, you file a Security Issues report.
Before you go any further, make very sure that you have fixed the problem. If you ask Google to review your fixes to a compromised site and they continue to find problems, it can increase the time it takes, and the difficulty of getting your site “cleared.”
This Google “Request a review” page describes how to check your site once you believe it’s clean. It also details the steps necessary to complete the Security Issues report. Those steps are different depending on the type of compromise your site has experienced.
Keep a Clean Backup Copy
I suggest that you make a backup copy of your WordPress website. If you run into issues such as this, you can quickly recover by restoring the site.
It’s important to make sure you have a backup copy of a clean site though. The last thing you want to do is restore a backup copy that contains the same malware you’re trying to get rid of.
For that reason, it’s important to keep as many backups you can for as long as you can. Especially if you manage a site that you aren’t updating or checking very often. Sites like those can be compromised for weeks before you realize there’s a problem, so an older backup is essential.
Keep Your Site Healthy
The best way to avoid malware on your site is to take measures to strengthen your security. Never assume your website is too small to be of any interest to hackers or bots. They are looking for vulnerabilities, they don’t care about size or popularity. It’s always better to err on the side of caution.
What is your favorite security plugin for WordPress? How often do you create backups of your site files and database?