10

When I use the site: operator to search for domains, it returns all the other matched subdomains as well. However, I only want to see what's indexed for the main site. For example:

site:google.com returns result of abc.google.com as well, but I only want to see what's on google.com

I don't want to use site:google.com -site:abc.google.com since I don't want to enumerate through all the other subdomains.

Is there a way to do "exact" match with the site: operator?

3 Answers 3

6

If the site starts with the subdomain www you can use just:

site:www.google.com

This should only show www.google.com (followed by a path), and not all the other *.google.com subdomains.

0
4

This works:

site:example.com -site:*.example.com

Just replace the domain with the one you're searching (duh)

0

Unfortunately this is not possible. That's one of the reason that in the past prevented me to switch from the www hostname to the non-www root domain.

In fact, if the main site domain starts with www, you can filter with

site:www.example.com

However, there is a small trick. Rather than using the site: operator you can try with inurl operator along with a +.

See for example

site:stackoverflow.com blog

vs

blog +[inurl:http://stackoverflow.com]

If you have multiple words to search for you may want to quote them if they are a single word.

"Ruby 2" +[inurl:http://stackoverflow.com]
3
  • Unfortunately inurl: will show all the URLs containing that string, resulting in other domains and subdomains appearing. Try: blog +[inurl:http://google.com] or click here. (I had inurl: in my initial edit, but removed it after testing variations of it).
    – dan
    Jan 12, 2014 at 10:54
  • This is true, there are several false positive, but while the number of false positive can be large if the domain is well known (such as google.com), in the majority other cases the query may return an acceptable result set. In any case, it is worth a a mention and a try ;) Jan 12, 2014 at 10:56
  • Yes, it depends on how popular the site is, and if it's referenced a lot in the URLs of other sites. For one user with not that large a site however, the results weren't usable, so after testing a few more sites, it seemed to not be a very reliable solution, especially with the OP's example usage of google.com.
    – dan
    Jan 12, 2014 at 11:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.