When I type in multiple search terms in the search box I expect to see results each of which contains all of those words and to see the words highlighted in the search results. This is the standard Google has set and pretty much all search engines that I can think of work this way, but apparently not the SO search engine. This makes it very difficult to avoid asking duplicate questions, as the search results are largely irrelevant unless you search for a single specific word.

Case in point, this very question has probably been asked but when I search for the string "search all words", whether with or without quotes, I don't see any relevant results. I get results containing the word "search" and a few of them even contain the word "words", but I can't see any that contains "search" and "all" and "words".

So how do I find relevant results when searching for multiple terms?

Edit: I appreciate people pointing out my mistake about how the Google search works (you learn something new every day!), but the question wasn't actually about the Google search - it was about the Stack Overflow search. The point is that I expect to see results relevant to all the terms I entered, not just some of them, and I don't see those on Stack Overflow. Is it possible to force it to match all the terms?

  • you said "When I type in multiple search terms in the search box I expect to see results each of which contains all of those words.." please point to me where the word 'tyrannosaurus' appears in the first search result for "tyrannosaurus anti-aircraft gun" Commented Aug 17, 2009 at 11:47
  • OK, so it's not in the first result for some silly reason, but it's in most others. I hope the intent of the question was still clear - how do I find search results containing all of the terms. Feel free to edit the question to clarify this, if needed.
    – EMP
    Commented Aug 17, 2009 at 12:30
  • Use Google search for what Google is good for, use SO search for what SO search is good for: meta.stackoverflow.com/search. Commented Aug 18, 2009 at 11:00
  • 6
    Oddly enough, this very page is now appearing as the first search result for "tyrannosaurus anti-aircraft gun". So Google is almost a self-fulfilling prophecy :)
    – Chris R. Donnelly
    Commented Sep 19, 2009 at 16:18
  • no longer valid ;o; Google (and therefore all search engines) officially abandoned every aspect that initially made them big in the first place because they can, people rely on it now, can't live without it, their schools, their phones, their networks, they infested the entire digital world, now they could probably make the first 2 pages of search ads without getting in trouble (they practically are). Their support for actual searching is no longer primary. Marketing strategies is now the primary drive, not searching, that is just illusion they are keeping up to keep business flowing. Commented Dec 19, 2023 at 1:28

6 Answers 6


There is a way to do this, but it's obscure.

Quotes trigger strict matching, like so:


But that strict matching search mode is typically only used for phrases. If you want it in words, you have to use quotes around each word:


compare with results from non-quoted version


I added an alias for this using plus:


If you want to ensure that the words appear in the results, start them with a plus:

+apples +oranges

  • 3
    @JeffAtwood Could you please give the authoritative answer to why SO search defaults to OR rather than AND? This is asked in a number of places and people either answer defensively or give theories and generally don't answer the question. Even your answer to the tyrannosaurus question seems defensive & doesn't answer question. Defaulting to OR certainly goes against the behavior most people have become used to. This is not an attack or a criticism it is just a statement. Can we put this question to bed once and for all? Me and I think others would just like to understand this. Thanks!
    – Howie
    Commented Feb 21, 2010 at 0:47
  • @Howie it's a long story; see documentation for technical details of SQL Server full text indexing. Commented Feb 21, 2010 at 8:42
  • @JeffAttwood So it relates to either a limitation in, or a difficulty in implementing with (I assume more likely an implementation difficulty than a limitation) SQL Server full text indexing? As long as it wasn't wasn't a SO design goal. :)
    – Howie
    Commented Feb 24, 2010 at 0:54
  • Hurray for that alias!
    – Arjan
    Commented May 2, 2010 at 10:02
  • this doesn't work. It still returns results that don't contain all the terms.
    – geoidesic
    Commented Nov 24, 2021 at 13:30

I had the same problem and have a mediocre workaround. Often when you have multiple word searches one of those words is likely a tag.

So for example if you wanted a search with all the words "vb6 dialog", but not necessarily that phrase, just rework your search as "[vb6] dialog"

You can also extend this to use more than one tag. "[vb6] [vb.net] dialog"

It ain't a perfect solution and only works when some or all of your terms are in the tags of the question you are looking for, but it is better than nothing.

  • thanks, the tag search with quotes worked very well
    – BlackICE
    Commented Mar 25, 2010 at 13:07

My observations (I'm playing devil's advocate, and trying to represent a newbie, who might not know about searching for answers with specific tag(s)):

Searching for "debug xml serialization" had as its first result (at time of writing) as: .NET XML serialization gotchas, which doesn't contain the term "debug"

Searching for "xml serialization debug" actually performs "[xml] serialization debug"

Questions tagged as [xml-serialization] are extremely poorly represented on the first page of results in either.


I think tyrannosaurus anti-aircraft gun is a spurious example.

As others have noted, [other dinosaur] anti-aircraft gun works as expected. It only shows pages that contain all of the terms. Only tyrannosaurus anti-aircraft gun seems to show pages that don't actually contain the word "tyrannosaurus".

Note also that when Google highlights the search results, in some cases it highlights the term "T-rex", a well-known synonym for "Tyrannosaurus rex."

I think what is happening is that Google is taking "T" as a synonym for "Tyrannosaurus." There's a Wikipedia page for "MG 42" that has the letter T in the templates at the bottom of the page. This seems to be sufficient for Google to consider it a match.

What about the YouTube video that's ranked even higher? My guess would be that, "T" being a common term, it's being omitted, and the page is being shown due to its high ranking for anti-aircraft gun.

Google does use AND, not OR, by default. But this can be obscured due to peculiarities such as the above.

(Additionally, Google regards a word as matching if it's used in link text pointing to a page, even if that word doesn't occur on the page itself. You can usually tell if this is the case by looking at the cached version of the page.)

BONUS: For more synonym fun, have a look at Google's top result for

keyup keydown dinosaur
  • Wow, my top result for keyup keydown dinosaur at home is different from my top result at work. I'm not sure what to make of that. The top result I was speaking of was this: msdn.microsoft.com/en-us/magazine/dd569752.aspx
    – user142148
    Commented Mar 21, 2012 at 0:35
  • I ran across another example today. Try searching on this: poor man's active directory. Google regards ad as a synonym for active directory, meaning I get results for poor man's ad, most of which in fact refer to advertisements. In its quest to be smart, Google is making itself stupid.
    – user142148
    Commented Jun 10, 2012 at 21:10

When I type in multiple search terms in the search box I expect to see results each of which contains all of those words ... This is the standard Google has set

are you using a different Google than I am?


I sure don't see the word "tyrannosaurus" in any of the first Google search results..

As for quoted phrases, that's valid, of course, but you open with a premise so incorrect that it's hard to get any further.

  • 1
    I do. So I guess we are using different Googles shrug. Anyway, the basic question was: how do I find only results that contain all of the search terms.
    – EMP
    Commented Aug 17, 2009 at 11:29
  • um, the first result is the wikipedia page en.wikipedia.org/wiki/Anti-aircraft_warfare which does NOT contain the word tyrannosaurus, even though it's plainly visible in my search terms. Your premise of "every word I type should appear" is completely and utterly wrong. Commented Aug 17, 2009 at 11:43
  • 7
    In lieu of just proving Evgeny wrong about Google, could you please at least address his question? Google does provide you a way to search for all terms in your search. If you search for tyrannosaurus and anti-aircraft and gun, you get pages with all of those words in them (4,750 of them. Thank you, Internet). We don't have an and operator, which is not fun, especially when searching for that one post you knew was there somewhere. I know the search isn't competing with Google, but a basic and operator would be shiny.
    – Eric
    Commented Aug 17, 2009 at 12:14
  • 2
    Utterly wrong, huh? That's basically how Google works in my experience too: results contain only pages for which all the search terms are relevant (somehow). As for the tyrannosaurus example, I guess someone must be linking to the page using that word, or when Google indexed it, the word appeared somewhere in the comments.
    – Jonik
    Commented Aug 17, 2009 at 12:23
  • @Jonik: The default behavior of Google is to actually pull back the most relevant pages for that search term. That does not include a blanket and. Jeff's right in that this is not how Google is designed nor intended to work. Of course, Google's relevancy engine is a little better than StackOverflow's, but hey, they had a head start.
    – Eric
    Commented Aug 17, 2009 at 12:25
  • Ignoring the result for this page, the top result was en.wikipedia.org/wiki/List_of_Decepticons Which does have all terms (as does the next result www.freewebs.com/zoideve/DinosaurDragon.htm ) Commented Aug 18, 2009 at 10:04
  • 2
    The test still works with a different dinosaur. I think this is a relatively recent (last couple of years) change in Google's behavior. For a while all terms would appear in the result, then all terms would appear either in the result or in pages linking to it, and now apparently it's just magic. However, "[less common dinosaur] and anti-aircraft and gun" does work. It sure would be nice if it worked on Stack Overflow, because showing me all results relating to dinosaurs when what I want is the handful of results that relate to both dinosaurs and anti-aircraft guns is not very helpful. Commented Sep 24, 2009 at 9:32

Google does not apply a blanket and. They have a pretty sophisticated relevancy engine which tells them what results to pull back. Most of the time, results contain all of the words, but they are not guaranteed to.

Instead, you need to use the and operator. So, to search StackOverflow for the words tyrannosaurus anti-aircraft gun and get posts will all of those words, you would search for this on Google:

tyrannosaurus and anti-aircraft and gun site:stackoverflow.com

The and operator makes all of the difference here. Of course, Google tends to pull back SO results better than SO, so unless you're using some of the advanced searching features, use the Google.

  • 5
    -1: "Google does not apply a blanket and" Actually, yes it does. "The AND operator, by the way, is the default, so it is not needed." google.com/support/websearch/bin/answer.py?answer=136861 Not only that, but Google only processes boolean operators if you capitalize them.
    – Powerlord
    Commented Sep 17, 2009 at 19:55
  • but not anymore :( advanced search modifiers now fail silently, they are stripped out from the search and reformed to what the MLA thinks you mean based on what everyone else searched for, and to a lesser degree, if you allow it, what you searched for, and unless configured otherwise, it will allow it, especially older accounts...just like this search i did, brought me here despite "verbatim" and "past year", yet I'm here, over 10 years ago.. wth Commented Dec 19, 2023 at 1:36

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .