Removing Site Links from Google

On rare occasions, you might accidentally submit web pages to be indexed in Google search results when you weren’t supposed to. There are both temporary and permanent measures to removing site links from Google if this happens.

Assuming that you’ve signed up to Google Search Console and verified your website, you’ll be able to use the Remove URLs feature in your Search Console account.

Removing Site Links from Google

Using this section to remove URLs is only a temporary measure, and successful requests to remove URLs will take effect for around 90 days.

Removing Site Links from Google

Simply click on the Temporary hide button, and enter the relative URL path of the link you would like to hide.

Removing Site Links from Google

Google will then start the process of removing your URL. Should you need to re-include the URL at some point, a Reinclude button will appear under the status column.

Removing Site Links from Google

What about Permanently Removing Site Links from Google?

Should you need to permanently remove links, Google will expect you to modify your web page so that it returns a particular response code or change the meta information within the page’s <head>. Alternatively, you can block access to the page such as enabling password protection.

The response code returned by your web server should either be 404 for Page Not Found, or 410 for Gone.

Updating the <meta name="robots"> meta tag to the below will prevent most search engines from indexing a page.

<meta name="robots" content="noindex">

If you just require Google to stop crawling web pages, you can replace robots with googlebot.

<meta name="googlebot" content="noindex">

To password protect web pages will depend on what web server you are using to serve your pages.

If you are using Apache, you can modify the .htaccess file to require authentication to view the web page.

Example syntax for this might look like the following.

AuthType Basic
AuthName "Password Protected Area"
AuthUserFile /path/to/.htpasswd
Require valid-user

Configuration for Nginx web servers might look similar to the below.

location /url-to-remove {
    try_files $uri $uri/ =404;
    auth_basic "Restricted Content";
    auth_basic_user_file /etc/nginx/.htpasswd;

Ensure that you check with your hosting provider about the correct syntax to use to password protect directories if you choose to remove URLs using this option.