How to use Google: search operators

April 08th, 2015 – 13 Comments

Search OperatorYes, you want to rank first in Google. And yes, you think you have optimized a site for that. But have you ever been playing with Google to see how your site is doing? Probably not, but let’s do that right now.

Have you ever used search operators in your Google queries? Search operators are parameters to narrow down your search results. It’s an ‘extra’ to add to your search query. Let me illustrate that by giving you some examples of search operators we frequently use while reviewing a website.

The site: search operator

“I’m using your plugin, but my site still isn’t indexed in Google.” If only we got a penny for every support email that starts like that. You can easily check if your site is in Google or not, by using this search operator:
site:yoast.com

Yes, our website is indexed. Now there are a number of reasons why you are not ranking very well, but your site definitely is in Google. Now let’s take that to the next level and see if the right page is ranking for that keyword we want to rank for:
site:yoast.com WordPress SEO plugin

The result:

Using a search operator to find the best ranking page

Using a search operator to find the best ranking page

Nailed it. What do you need to look for in these search results?

  • Is your homepage ranking first? Unless you searched for your brand name, you probably want to set up a cornerstone page for the keyword and make that one rank first.
  • Is the page you expected to rank first not ranking first? Compare that page to the page tha is ranking first. What does the WordPress SEO Page Analysis tell you? Perhaps you’ll also find that the other page has a lot more backlinks. That might be a reason to further optimize the currently ranking page instead, for instance.
  • Is a taxonomy page ranking first? That could make sense, with all the post linking to that category or tag page. But is that page optimized? Do you think it qualifies as the main page for the topic? Does it have a nice introduction or just the post excerpts? If not, please read WordPress Archive Pages: the tutorial.

The intitle: search operator

I like this search operator. You can check just about anything with it. Let’s start with open directories. I always really dislike ending up on an Explorer like folder overview. These pages shouldn’t be indexed in the first place. A simple check for your own website is:
intitle:"Index of"

I used the double quotes just to make sure the exact phrase is found. If you want to take that a step further, you could even make it intitle:"Index of" Last Modified, which searches for Last Modified on any page that has Index of in the title.

If we combine both search operators, we can narrow this down to our own site:
site:yoast.com intitle:"Index of /" Last Modified

Pfiew, no open directories indexed.

The inurl: search operator

Have you ever wondered what these WordPress attachment pages are for? It’s a bit like automatically generated thin content for your website. We advise against using these, and even have an option to prevent these in our WordPress SEO plugin. Just go to SEO › Advanced › Permalink (tab) and check “Redirect attachment URL’s to parent post URL.” This will make sure that any visitor that ends on a specific attachment page, is redirected to the page where the (f.i.) image is used. Just make sure all images are attached / uploaded to a certain page or post. That can be easily checked by visiting your media library and enabling the Uploaded to column at Screen options.

Back to the inurl search operator. That one comes in handy when you want to check if any of these attachment pages is indexed. The thing is, that every attachment page URL has ‘attachment_id’ in it. The search query we are looking for is obviously:
inurl:attachement_id

Note that I skipped a number of results, as the first results on that query are WordPress.org pages telling us we have these pages and what they do. Not much :) Find these on your site using a combination with the site: search operator and make sure to redirect them to the parent posts and pages they are used on.

Your turn

That’s just three of a number of search operators that are available. Use these to your advantage. Looking forward to any creative uses you have found for these search operators. Please share them in our comments!


13 Responses to How to use Google: search operators

  1. Jeroen
    By Jeroen on 17 April, 2015

    And if i have open directories how can i prevent that. Is it an option in the seo plugin? (result:site:www.mysite.com intitle:”Index of /” )

    • Joost de Valk
      By Joost de Valk on 17 April, 2015

      No, those fall outside the domain of WordPress, you should fix those either by changing your server config or by having an empty index.html or index.php file in that directory.

    • Michiel Heijmans
      By Michiel Heijmans on 17 April, 2015

      Hi Jeroen,

      No, it’s not an option in the plugin. Easiest would be to add an index.php in that directory. Just include a redirect in that file to your homepage.

  2. seo uzman?
    By seo uzman? on 16 April, 2015

    The search engine list: related:google.com
    Thanks for article!

  3. James Lust
    By James Lust on 11 April, 2015

    Using Google operators is very helpful in SEO analyze, everyone should have them in mind, thanks for article!

  4. Manuj
    By Manuj on 11 April, 2015

    Hi Michiel,

    Great post, I most of the times check this website to optimise the website for SEO.

  5. Tiffany Jacobs
    By Tiffany Jacobs on 11 April, 2015

    Hi Michiel, great post. Thanks for sharing those tips, they are very usefull for me.

  6. Peter
    By Peter on 10 April, 2015

    Hi Michiel,

    Thanks for the post. Should I redirect the category page to the cornerstone page If that category page is ranking above the cornerstone page? There is no benefit in the category page.

    The quality of the cornerstone is way better for readers then that category page and I mention and linkto all the interesting posts in de the cornerstone page.

  7. Nigel Abery
    By Nigel Abery on 9 April, 2015

    Hi Michiel, great post. I often use the site: command but obviously there a lot of others that could be very useful, like those you mentioned.

  8. Ritesh Dutta
    By Ritesh Dutta on 9 April, 2015

    I have often tried this while searching specifically pdf or ppt file on internet. It really does come in handy.
    Thanks for the post

  9. Leon Ridge-Cooke
    By Leon Ridge-Cooke on 9 April, 2015

    I prefer the link: operator myself.

    • Michiel Heijmans
      By Michiel Heijmans on 9 April, 2015

      What do you do with it, Leon? Just check which sites are linking? And what is the benefit over tools like OSE and Majestic? Just wondering :)

  10. Angelos Savvaidis
    By Angelos Savvaidis on 8 April, 2015

    You can always use

    info:www.example.com

    and it will give you some nice options if you can’t remember the search operators.


Check out our must read articles about Analytics