Changes

Jump to navigation Jump to search
→‎Prefixed hyphen character for exclusion: change section title for consistency, per edit request. Nothing mentions the old section heading, so no need for an anchor.
{{pp-protected|small=yes}}
{{About|searching Wikipedia|navigating|Help:Navigation#Using the search box to navigate}}
{{further|mw:Help:CirrusSearch}}
{{Wikipedia how to|H:S|WP:S|H:SEARCH|WP:SEARCH}}

Wikipedia uses a [[#Under the hood|powerful search engine]], with a ''[[#Search box|search box]]'' on every page. The search box will navigate directly to a given ''page name'' upon an exact match. But, you can [[H:FORCE|force]] it to show you a page of search results instead (by including a tilde character ~ anywhere in the query), to see what else Wikipedia has that includes your [[#Search string|search string]]. The maximum search string is 300 characters long.<ref name=Phabricator>See [[WP:Phabricator|Phabricator]] task {{phab|T107947}} for an explanation.</ref> However, search can instantly search all {{NUMBEROFPAGES}} pages on the wiki when the search is kept to a simple word or two.

Wikipedia's searches can be made domain-specific (i.e., search in desired namespaces). The search engine also supports [[#Special characters|special characters]] and [[#Parameters|parameters]] to extend the power of searches and allow users to make their [[#Search string|search strings]] more specific.

Advanced features of the Wikipedia search engine include multi-word proximity-searches (in which the user indicates how close the words in a phrase might be), wildcard searches, "fuzzy~" searches (handles typo-correction and questionable spelling), and several wiki-oriented operators and parameters for weighting and filtering. Search can also handle [[regular expression]]s, a sophisticated, exact-string, and string-pattern, search tool that is not offered by most public search engines.

Search can also filter results by template names used, [[WP:CATEGORY|category]] membership, or pages linking to a specific page.

[[Special:Preferences]] offers several search options, and [[Wikipedia:Tools#Searching|Wikipedia:Tools § Searching]] offers the setups of other users.

== Search box ==
[[File:Search box monobook.PNG|thumb|left|Monobook places this search-box in the left toolbar.]]
[[File:Search box vector.PNG|thumb|left|Vector skin, simplified search box.]]

The search box is an input box with the term "Search Wikipedia" in it. In the Vector skin, it is located in the top right corner of the screen. In Monobook, it is in the middle of the sidebar on the left of the screen.

To use the search box, click in it, or jump to it, and type in your [[#Search string|search string]]. To jump to the search box, "'''f'''ocus" your cursor to there by pressing {{Keypress|Shift|Alt|F}}.

In Vector, instead of a search button, there is an icon of a magnifying glass on the right-hand end of the search box. Pressing {{Keypress|Enter}} or clicking on the magnifying glass when the box is empty takes you directly to Wikipedia's [[#Search page|search page]].

If your search matches a page name the search box may {{em|navigate}} instead of search. To get {{em|search results}} instead, prepend the tilde <kbd>{{big|~}}</kbd> character to the first word of the title. (Or choose "{{font color|grey|{{int:Searchsuggest-containing}}}}" from the suggestions that drop down as you type.)

[[JavaScript]] and [[WP:skin|skin]]s have an effect on the search/navigate default behavior. Monobook's default is to navigate, and Vector's default is search; however when JavaScript is on, the Vector skin will navigate. Monobook's {{button|Go}} will navigate, and is the default, but Monobook has a {{button|Search}} button.

== Search string ==
{{anchor|search query}}

Whatever you type into the [[Search box#|search box]] is called the "search string". It may also be referred to as the "search query".

A basic search string is simply the topic you are interested in reading about. A direct match of a basic search string will navigate you directly to Wikipedia's article that has that title. A non-match, or any other type of search string will take you to Wikipedia's search results page, where the results of your search are displayed.

Terms in the search string are subject to [[#Stem matching|stem matching]], except for anything included between double quotation marks.

You can include in your search string [[#Special characters|special characters]] and [[#Parameters|parameters]] that activate specific search capabilities. Using any of these will take you to Wikipedia's search results page with the results of your search displayed.

The maximum search string is 300 characters long.<ref name=Phabricator/>

What you can type in to do various things is called [[#Search string syntax|search string syntax]]...

== Search string syntax ==

Search is case insensitive, that is, upper and lowercase is ignored.

Search "folds" character families, matching similar-looking letters across alphabets, to match foreign terms. So, you don't have to type in [[diacritical]] letters, and your terms will still match. For example, [[Citroen]] will match [[Citroën]], and [[Aeroskobing]] matches [[Ærøskøbing]].

Characters that are not numbers or letters (punctuation marks, brackets and slashes, math and other symbols) are generally ignored. It is not possible to search for the string <kbd>|LT|</kbd> (letters <kbd>LT</kbd> between two pipe symbols) as used in some unit-conversion templates for long tons; all articles with <samp>lt</samp> will be returned. Some characters are treated differently; <kbd>Credit&nbsp;(finance)</kbd> will return articles with the words <samp>credit</samp> and <samp>finance</samp>, ignoring the parentheses, unless an article with exact title <code>[[Credit (finance)]]</code> exists.

The source text is what is searched, which is not always what is displayed on the screen. This distinction is relevant for [[Wikipedia:Piped link|piped links]], for [[Wikipedia:interlanguage link|interlanguage links]] (to find links to Chinese articles, search for <kbd>zh</kbd>, not for <kbd>Zhongwen</kbd>), [[Help:Special characters|special characters]] (if <samp>ê</samp> is coded as <code>&amp;ecirc;</code> it is found searching for <kbd>ecirc</kbd>), etc.

For [[regex]] searches, see the <code>[[#insource:|insource:]]</code> parameter below.

=== Namespaces ===

The default search domain is the article space, but any namespace may be specified in a query.

At the search results page, any number of [[WP:NAMESPACE|namespaces]] can be specified, and [[Wikipedia:Users|users]] can keep those namespaces as their own default search domain. Partial namespace searches can be made by specifying the initial letters of a page name.

=== Spaces ===

The use of spaces is, in general, intuitive. Unnecessary spaces, and all non-alphanumeric characters except <code>"</code> are ignored, which makes for flexibility; it is simplest and best to avoid typing unnecessary spaces, although the tolerance for grey space simplifies copying and pasting search terms without the need for cleanup. For example, <code>credit AND card</code> is obviously reasonable, <code>creditANDcard</code> is not; copying and pasting <code><nowiki>[[Credit(?!)card]]</nowiki></code> is equivalent and convenient; <code>"credit card"AND"payment card"</code> is actually correct and minimal, but <code>"credit card" AND "payment card"</code> is a sensible equivalent.

Any of the following characters will be treated as a [[space character]]: <code>!@#$%^%^&*()_+-=~`{}[]|\:;'<>,.?/</code>. The double quotation mark <code>"</code> is not one of these characters, because it has the special purpose of specifying an exact phrase search (see more below). We use the term ''grey-space'' instead of ''[[Whitespace character|whitespace]]'' here to include the space character itself and all these characters. Multiple [grey-]spaces are equivalent to a single space, and when used between terms to AND.

Grey-space is ignored within and around logical terms, between the words of exact-phrase searches, between adjacent items in the query, and in starting characters of the search box query. All filters can have grey-space between them without affecting search results. Most operators, such as <code>intitle:</code> and <code>incategory:</code>, ignore unnecessary spaces, or grey-space, after the colon.

Where spaces are significant: single search terms cannot have embedded spaces; <code>work space</code>, <code>"work space"</code>, and <code>workspace</code> are all different. The particular keywords ''prefix'' and ''insource'' must be followed immediately by a colon<code>:</code>and their arguments, without intervening [grey-]spaces.

=== Special characters ===
{{shortcut|H:SPCHAR|WP:SPCHAR}}

For [[regex]] searches, see the <code>[[#insource:|insource:]]</code> parameter below.

==== Double quotes for exact phrase search ====
{{anchor|double quotes}}

A [[phrase]] can be matched by enclosing it in double quotes, <kbd>"like this"</kbd>. Double quotes can define a single search term that contains spaces. For example, ''{{Search link|"holly dolly"}}'' where the space is quoted as a character, differs much from ''{{Search link|holly dolly}}'' where the space is interpreted as a logical AND.

==== Suffixed tilde character for fuzzy search ====
{{anchor|fuzzy search|respell}}<!-- Please leave anchors in place. Section redirects point to them. -->
{{short|H:FUZZY|WP:FUZZY}}

[[Approximate string matching|Spelling relaxation]] is requested by suffixing a tilde (<kbd>~</kbd>) like <kbd>this~</kbd>, with results like "thus" and "thins". It covers any two character-changes for any character except the first: it returns addition, exchange, or subtraction. This search technique is sometimes called a "sounds-like" search. For example, searching for ''{{search link|charlie~ parker~}}'' returns ''Charlie Parker'', ''Charles Palmer'', ''Charley Parks''.

==== Prefixed tilde character for forced search ====
{{anchor|forced search}}<!-- Please leave anchors in place. Section redirects point to them. -->
{{short|H:FORCE|WP:FORCE}}

To force a search rather than navigate directly to a matching page, include a tilde character <kbd>~</kbd> anywhere in the query. It always takes you to the search results page, never jumping to a single title. For example, the misspelling <kbd>similiar</kbd> is [[WP:Redirect|redirected]] to the [[Similarity]]<!--Intentional disambiguation link.--> article, but prefixing a tilde, ''{{search link|~similiar prefix:{{FULLPAGENAME}}|~similiar}}'', lists pages containing that misspelling.

==== Prefixed hyphen character for exclusion ====
{{anchor|exclusion|hyphen}}<!-- Please leave anchors in place. Section redirects point to them. -->
{{shortcut|H:EXCLUDE|WP:EXCLUDE}}

Pages matching a search term can be excluded by prefixing a hyphen or dash (<kbd>-</kbd>) to the term. This is the [[logical NOT]]. For example, ''{{Search link|credit card -"credit card"}}'' finds all articles with "credit" and "card" {{em|except}} those with the phrase "credit card".

==== Wildcard characters ====
{{anchor|wildcard|wildcard search}}<!-- Please leave anchors in place. Section redirects point to them. -->
{{shortcut|H:WLD|WP:WLD}}

The two wildcard characters are <kbd>*</kbd> and <kbd>\?</kbd>, and both can come in the middle or end of a word. The escaped question mark stands for one character and the star stands for any number of characters. Because many users ask questions when searching, question marks are ignored by default, and the escaped question mark (<kbd>\?</kbd>) must be used for a wildcard.

{{clear}}

==== Logical operators ====
{{shortcut|H:BOOLEAN|WP:BOOLEAN|H:LOPS|WP:LOPS}}

The search engine supports boolean logic in searches. The logical operators include the "<kbd>-</kbd>" (minus sign) character for "logical not", the <kbd>AND</kbd>, the <kbd>OR</kbd>, and the grouping parentheses brackets: (_).

Logical <kbd>OR</kbd> must be spelled in capital letters; the <kbd>AND</kbd> operator is assumed for all terms (separated by spaces), but capital <kbd>AND</kbd> is equivalent. Parentheses are a necessary feature because:&nbsp; {{nowrap|<kbd>(blue OR red) AND green</kbd>}}, differs from: {{nowrap|<kbd>blue OR (red AND green)</kbd>}}.

=== Parameters ===
{{anchor|Parameter searches}}<!-- Please leave anchors in place. Section redirects point to them. -->
{{about|search parameters|template parameters|Help:Template#Parameters|section=yes}}
{{shortcut|H:PARAM|WP:PARAM}}

Parameters function as name filters, each followed by the search term it operates on. Their search term may be a word or a phrase. The main parameters are '''{{var|namespace}}:''', '''intitle:''', '''insource:''', '''incategory:''', and '''prefix:'''. ("namespace" as used here isn't literal – use the name of the actual namespace desired).

"prefix:" differs from the other parameters in that it can only be used at the end of a search string.

These make up items in a query, and so they accept logical operators between them. A single "{{var|namespace}}:" filter can go first, and a single "prefix" filter can go last.
<!-- Note that the [[space character]]s are {{em|not}} very important except around "prefix". The query string of "incategory" is a [[WP:Page name|page name]] (or "a category name"), and in a page name, the [[underscore]] is equivalent to space, and so underscore will suffice instead of the double quotes around the page name with spaces in it. The "intitle" query is not a page name, but it also treats space and underscore equally, treating them as AND. (It even treats multiple spaces, and even mixes of spaces and underscores that way.) All filters can have between them multiple spaces (or underscores) (or a mix) without affecting search results. Multiple spaces are treated as a single space everywhere except around "prefix". (Namely, within and around Boolean operated terms, even if inside double quotes; in between adjacent filters; in page names; in starting characters of the search box query; in between the colon and the prefix parameter names "incategory", "intitle", or "all", or after that colon). "Prefix:" or a namespace name (or its alias) can have no space between its name and the following colon. And remember, "prefix:" is entirely literal after its colon, and so treats no space character, except as a space.-->

==== {{var|namespace name}}: ====

A reader searching for articles from the search box need know nothing about namespaces, so the default [[WP:User preferences help|user preferences]] are set to search only in article space; but an advancing editor can reset the default search-space preference for the current search to a particular namespace, or "all" by prefixing the search with "all:" or the namespace name followed by a colon.

Given only at the {{em|beginning}} of the query, a namespace name followed by a colon limits search results to that namespace. It is a filter without a query string. Namespace [[WP:Namespace#Aliases|aliases]], like "WP" for "Wikipedia", are accepted.

==== All: ====
{{shortcut|H:ALL}}

Prefixing "All:" to a search string, searches all namespaces, and prioritizes mainspace matches to the top.

==== all: ====

Using the lower-case "all:" version also searches all namespaces but does not prioritize the results by namespace.

==== intitle: ====
{{shortcut|H:INTIT|WP:INTIT|H:INTITLE|WP:INTITLE}}

[[Help:Page name|Page titles]] can be searched with "intitle:{{var|query}}". The search results highlight occurrences in both the title and page content. Multiple "intitle" filters may be used with Boolean operators between, such as {{nowrap|"intitle:speed OR intitle:velocity"}}, but "intitle:speed OR velocity" also works. [[Regular expression]]s can be used with "intitle:/{{var|regexp}}/" or the case insensitive "intitle:/{{var|regexp}}/i". See more in the [[#insource:|insource]] section.

{| class="wikitable"
|-
! Query
! Description
|-
| {{search link|intitle:airport}}
| All articles with airport in their title
|-
| {{search link|parking intitle:airport}}
| Articles with "parking" in their text and "airport" in their title
|-
|style=white-space: nowrap | {{search link|intitle:international intitle:airport}}
| Articles containing "international" AND "airport" in their title (including ''Airports Council International'')
|-
| {{search link|intitle:"international airport"}}
| Articles with the phrase "international airport" in their title
|}

==== insource: ====
{{shortcut|H:INSOURCE|WP:INSOURCE}}

This can find template arguments, URLs, links, html, etc. It has two forms, one is an indexed search, and the other is regex based.
{{clear}}
{|class="wikitable"
|-
! Query
! Description
|-
|<code>insource:{{var|word}}</code><br /><code>insource:"{{var|word1&nbsp;word2}}"</code>
|Like word searches and exact-phrase searches, non-alphanumeric characters are ignored, and proximity and fuzziness are options.
|-
|<code>insource:/{{var|regexp}}/</code><br /><code>insource:/{{var|regexp}}/i</code>
|These are [[regular expressions]]. They use a lot of processing power, so we can only allow a few at a time on the search cluster, but they are very powerful. The version with the extra <code>i</code> runs the expression case-insensitive, and is even less efficient. Regex searches are likely to time out unless you further limit the search in some way, such as by including another parameter or a search term outside of the insource component of the search string.
|}

==== incategory: ====
{{anchor|incategory|Incategory}}<!-- Please leave anchors in place. Section redirects point to them. -->
{{shortcut|H:INCAT|WP:INCAT|H:INCATEGORY|WP:INCATEGORY}}

Given as "incategory:{{var|category}}", where {{var|[[Help:Category|category]]}} is the [[Help:Page name|page name]] of a category page, it lists pages with <kbd>[<nowiki />[Category:{{var|page name}}]]</kbd> in their wikitext. (Editors searching in namespaces other than mainspace will need to know [[WP:TCAT|the limitations]] these search results may contain.) Space characters in a page name can be replaced with an underscore instead of using double quotes; either way works, and even both at once works (but not on commons). "Incategory:" will also return pages in the adjacent subcategory; see for example, {{nowrap|"{{search link|category: incategory:History}}"}}. Multiple "incategory" filters may be applied. A more graphical alternative to a single filter is at [[Special:CategoryTree]]. Because categories are important structures for {{em|searching}} for related articles, any use of this prefix is particularly effective for searching. For more on using the categories themselves to find articles, see [[Wikipedia:FAQ/Categories]].

{| class="wikitable"
|-
! Query
! Description
|-
| {{search link|ammonia incategory:German_chemists}}
| Starting with the articles listed at ''[[:Category: German chemists]]'', only the ones that have the word "ammonia" in their text
|-
| {{search link|incategory:"Suspension bridges in the United States" incategory:Bridges_in_New_York_City}}
| Articles that are [[WP:CI|common to both categories]]—the suspension bridges in New York City
|-
| {{search link|"feral cat" -incategory:"Category:Cats in the United Kingdom"}}
| Articles that contain the phrase "feral cat", but not listed in ''[[:Category:Cats in the United Kingdom]]''
|}

==== deepcategory: ====
{{shortcut|H:DEEPCAT|WP:DEEPCAT}}

Also <code>deepcat:</code>, this allows you to search in a category and all its subcategories. The depth of the tree is currently limited to 5 levels, and the overall number of categories is limited to 256.

Example:

<code>deepcat:"musicals"</code>

Finds articles that are in [[:Category:Musicals]] or any of its subcategories.

==== prefix: ====
{{shortcut|H:PREFIX}}

"prefix:{{var|page name}}" patterns {{em|only the beginning characters}} of a [[WP:Page name|page name]]. Because the "beginning" characters can, if you need, go on to include the characters all the way to the end of the page name, prefix must include spaces, since page names often include spaces. For this reason ''prefix:'' must only ever be given at the {{em|last part}} of a search box query, and next character after the colon cannot be a space. Prefix does not search for partial namespace names, but requires at least a full namespace name to start to find pages, but ''prefix:'' also recognizes an [[WP:Namespace#Aliases|alias]] of a namespace, and it recognizes redirects (or shortcut). Prefix is the most widely used and powerful filter as it can mimic the namespace filter, and because ''intitle:'' cannot easily target a single page, even together with other filters. [[Special:PrefixIndex]] is a MediaWiki, graphical, version, using only ''prefix:'' to find pages.

{| class="wikitable"
|-
! Query
! Description
|-
| {{search link|Salvage wreck prefix:USS}}
| Articles containing the words ''salvage'' and ''wreck'' whose title starts with the characters "USS"
|-
| {{search link|wave particle prefix:Talk:Speed of light}}
| ''Speed of light'' talk pages with the terms "particle" and "wave", including the current and the archived talk pages
|-
| {{search link|wave particle prefix:Talk:Speed of light/}}
| Same search, but only in the [[WP:Archive|archived]] [[WP:Subpage|subpages]]
|-
| {{search link|"portal namespace" readers prefix:Wikipedia talk:}}
| Is equivalent to 'Wikipedia talk:"portal namespace" readers'
|-
| {{search link|Talk:"heat reservoir" OR "ocean current"}}
| Any discussion page in the entire encyclopedia with either of those phrases, including archived discussions
|-
| {{search link|language prefix:Portal:Chi}}
| Portal namespace page names that begin with "Portal:Chi" and have the word ''language'' in the page
|}

==== linksto: ====
{{shortcut|H:LINKSTO|WP:LINKSTO}}

"linksto:{{var|page name}}" searches in pages that link to the given page. Can be used negatively by prefixing a hyphen, which will return pages that {{em|do not}} link to the given page. Unlike with some other keywords, the page name is case-sensitive.

{{clear}}
{| class="wikitable"
|-
! Query
! Description
|-
| {{search link|linksto:Airport}}
| All articles containing internal link to [[Airport]].
|-
| {{search link|parking linksto:Airport}}
| Articles with "parking" in their text linking to [[Airport]]
|-
| {{search link|-linksto:"Albert Einstein" "Albert Einstein"}}
| Articles containing "Albert Einstein" NOT linking to [[Albert Einstein]]
|}

==== subpageof: ====
{{shortcut|H:SUBOF|WP:SUBOF}}

{{A note|Important note}} This only works right in the search box of the search page or search results page.

This limits searches to subpages of the specified page. You can also negate the subpages from a search by preceding subpageof: with a hyphen. Note that articles on Wikipedia generally don't have subpages, but the pages of the other namespaces do. Therefore, use the namespace parameter also. Here are some examples:


To look at all the subpages of a user, try this:

<code>User: subpageof:AzaToth</code>

That will display all the subpages of [[User:AzaToth]]


To make sure Articles for deletion pages do not show up in the results of a Wikipedia namespace search, try this:

<code>Wikipedia:"Hi there" -subpageof:"Articles for deletion"</code>

That'll show pages from the Wikipedia namespace with "Hi there" in them, and the list of results will not be cluttered with any Articles for deletion debates (many thousands of which are in the Wikipedia namespace). Notice the use of the hyphen (that makes it mean "not subpages of".)

==== hastemplate: ====
{{shortcut|H:HASTEMP|WP:HASTEMP}}

This finds pages that use the specified template. Input the canonical page name to find all usage of the template, but use any of its redirect page names finds just that naming. Namespace aliases are accepted, capitalization is entirely ignored, and redirects are found, all in one name-search.

This is more thorough than insource:, in that it will find meta-templates (templates called by another template). Meta-templates don't show up in the local page's wikitext.


Examples of hastemplate: usage:

<code>hastemplate:"Article for deletion/dated"</code>

This lets you find all the articles being considered for deletion.


<code>intitle:"Outline of " AND -hastemplate:"Outline footer"</code>

This lets you find Wikipedia outlines that are lacking the outline footer template. (Notice the use of the hyphen to indicate "NOT").

== Search page ==
[[File:Search page.PNG|thumb|300px|alt=Wikipedia special search box|The search page.]]

The search page features a search box, with some links to search domains beneath it. For information on what can by typed into the search box, see [[#Search string syntax|Search string syntax]] above.

The main difference between this search box and the one that appears on article pages is that exact matches on this one will not navigate you directly to an article page. This search box will produce the [[#Search results page|search results page]] showing what all matches your search on Wikipedia.

To get to the search page, do an empty search (press {{Keypress|Enter}} while in the [[#Search box|search box]] before typing anything else in), or click on the magnifying glass in the search box. The link [[Special:Search]], which can be inserted onto user pages or project pages, for example, also leads to the search page.

For an explanation of search domains, see [[#Refining results|Refining results]] below.

While the entire contents of the search page is included in the [[#Search results page|search results page]], it is a distinct page. User scripts might be designed to work on the search results page but not the search page, for example.

== Search results page ==
{{shortcut|H:RESULTS|WP:RESULTS}}

The search results page looks just like the [[#Search page|search page]], with the results for your search query presented below it. For information on what can by typed into the search box, see [[#Search string syntax|Search string syntax]] above.

The search results page is displayed when a search is done from the search page, when a search from the regular [[#Search box|search box]] does not exactly match a page title, or when any parameters or special characters are included in a [[#Search string|search string]].

Terms included in the search string will be displayed in bold in the details of the results, for easy modification.

=== Understanding search results ===

The search string entered will be displayed in the search box on the page, in case you wish to modify it.

Spelling corrections and query corrections are offered at the top of the results (''see [[#Preliminary reports|Preliminary reports]], below'').

Note that search results include content from templates displayed on the pages searched.

The order that search results are presented in is based on the page ranking software.

Results match word stems, along with their various tenses (past tense, plural tense, etc.), except for anything included between double quotation marks. ''See [[#Stem matching|Stem matching]], below.''

Throughout the results, matching terms are highlighted in bold. All matches in the title show for sure, while matches within the details may show, but not if they are far apart on the page.

Matches are included for section headings, members of matching categories, and destination pages of redirects. These will show off to the side of the page name, parenthetically.

A single result (one each) from selected sister projects appears on the right side of the page (the most likely relevant match for each). This feature may be permanently turned off in [[Special:Preferences|Preferences]].

Files from Wikimedia Commons are mixed included within the results, when the "File:" namespace has been selected (in Advanced search).

==== Preliminary reports ====

Search results will often be accompanied by a preliminary report.
* '''There is a page named "{{font color|#0645AD|{{var|Page name}}}}"''' (a wikilink to an existing page)
* {{font color|#CC2200|Did you mean:}} {{font color|#0645AD|{{var|spelling correction}}}} (either a wikilink or a search-link)
* ''You may create the page "{{font color|#CC2200|{{var|New title}}}}"'' (a redlink to a new page name)
The ''Did you mean'' report corrects dictionary word spellings and gives a link
that is either a wikilink that will navigation to an article
or a search link that will perform a query.
The distinction can be made by observing the presence of a ''You may create the page'' report.
Another report corrects "spellings" to coincide with any "word" found in a search index (any word on the wiki).
:{{font color|#CC2200|Showing results for}} {{font color|#0645AD|'''{{var|query correction}}'''}}. {{font color|#CC2200|Search instead for}} {{font color|#0645AD|{{var|your query}}}} (two search links).<!--
--><section end="Search results page" /><section begin="Refining results" />

==== Stem matching ====
{{shortcut|H:STEM|WP:STEM}}

Search results will include the roots of words included in the search string, and their various tenses (plural, past-tense, etc.). If stem matching is not wanted, use double quotes around the word or phrase you want to match verbatim. Here are some examples:

{| class="wikitable"
|-
! Query
! Description
|-
| {{search link|stem prefix:{{FULLPAGENAME}}|stem}}
| Matches "stem", "stemming" or "stems", etc.
|-
| {{search link|cloud prefix:{{FULLPAGENAME}}|cloud}}
| Matches "cloud", "clouds", "clouding", or "clouded", etc., but not "cloudy".
|-
| {{search link|"stemming" prefix:{{FULLPAGENAME}}|"stemming"}}
| Matches "stemming" but not "stemmed" or "stems", etc.
|-
| {{search link|"clouds" prefix:{{FULLPAGENAME}}|"clouds"}}
| Matches "clouds" and "cloudsource", but not "clouding", or "cloud", etc.
|}

=== Refining results ===
{{shortcut|H:REFINE|WP:REFINE}}
[[File:Search page.PNG|thumb|300px|alt=Wikipedia special search box|Special search box just for ''Search'', with the general search domains listed below. Click on one to search that domain.]]

[[File:Search page advanced July 2014.png|thumb|350px|alt=Some Wikipedia simplified search options|Clicking on Advanced shows the namespaces of the wiki. Check namespaces to set either your current or your default search domain.]]

The ''Search'' page is designed for presenting and refining results in a re-search loop controlled by modifying the query or clicking on a search domain.
* Add a ''filter'' such as <kbd>-{{var|word}}</kbd>{{space}} or sort by date with {{space}}<kbd>'''prefer-recent'''</kbd>.
* Note the number of search results to the right.
* Note your search terms in bold in the ''snippet'', and use that context to modify your search.

[[WP:article|Articles]] are in the main [[Help:Namespace|namespace]], or "article space", but ''[[Special:Statistics]]'' will show that there are many times more ''pages'' on Wikipedia than there are ''articles'' on Wikipedia. Other ''types'' of pages are in other ''namespaces'', and these can be searched by clicking one of the search domains in the grey frame just below the search box. Its blue font turns black to show that it represents the search results.
* If ''Multimedia'' is clicked matching images, videos and audios are then listed. These are in the '''''[[WP:Files|File]]''''' namespace on the wiki, and on the ''[[Wikimedia Commons]]'' web site, which is also searched.
* If ''Everything'' is clicked, matches to every page on the entire wiki are then listed. Everything includes all the namespaces on the wiki, (including '''''Help''''' and '''''Wikipedia'''''). These are listed in Advanced.
* If ''Advanced'' is clicked, a ''profile'' of previously set namespaces is then searched, and a gray frame expands to reveal the ''profile''. All the namespaces of the wiki are listed there, and the ''search domain'' is indicated by check marks. Click All to match the Everything search domain to the left; clicking none requires selecting namespaces to have an effect. To set your default search domain, at the bottom click "remember", and then click "Search" to set it. To collapse the frame again, you must perform another search, either by clicking on one of the other search domain offerings, or by removing the <small><kbd>&profile=advanced</kbd></small> parameter in your browser's URL in the address bar, and entering that search.

In order to fully interpret the search results page, check which search domain is in black font, but also remember to check for a namespace name at the beginning or a ''prefix:'' parameter at the end of the search box query:
* When the ''search domain'' consisted of two or more namespaces<ref>A search link can set a search domain to two or more namespaces, or all namespaces</ref>, an expanded "Advanced" frame below the search box, a ''profile'', will indicate that, because only one namespace can fit in the shown query.
* A namespace entered in a query always takes priority for determination of the search domain of a query, and will at any time override your default search domain, or any displayed ''profile''.
* A ''prefix:'' parameter at {{em|the end}} of a query in the search box, furthermore, will override any namespace there, or any ''profile'' underneath that.
Equivalently, you could check the [[WP:URL|URL]] in your browser's address bar for profile and namespace parameter settings, because the search query was sent to the search engine by way of that URL.

The search results page is designed for refining results:
* Terms included in the search string will be displayed in bold in the details of the results, for easy modification.
* The search query that produced the results is displayed in the search box, so you can edit the query and get new search results.
* The number of matches is displayed to the right.
* Add a ''filter'' term such as <kbd>-{{var|word}}</kbd> or <kbd>incategory:{{var|page name}}</kbd>
* You can modify the ''search domain'' to be "Content", "Multimedia", or "Everything" (by activating that word).
* Click advanced to specify which namespaces to search

== Search settings ==
{{anchor|User preferences}}
{{main|Help:User preferences}}

There is a {{myprefs|Search}} tab. (You must be logged in.)

The ''default search domain'' is article space, but any user can change this default, and have their own ''default search domain'' for all the queries they run. In any case a query always can specify a namespace to make the search domain explicit and override any default. At the search results page, [[Special:Search]], ''Advanced'' dialog, a search can specify any number of namespaces, and a [[Wikipedia:Why create an account|logged-in users]] can set their ''default search domain'' there by clicking "Remember selection for future searches".<ref>Because the default search domain is a settable preference, any query you intend to share, publish, or save in a search link might need the search domain explicitly given in the search link in order to ensure consistent search results among all users, at any time. {{tl|Search link}} defaults to article space but can specify multiple namespaces in its query.</ref>

Visit your {{myprefs|Gadgets}} page (requires JavaScript) to set up:
* several external search engines' views of Wikipedia. The search results page will then have a pull down list to the left of its search box, offering your choice as, say, a modification of a word or phrase search, or a page ranking refinement. Go to {{myprefs|Gadgets}} ''Appearance'', and see "Add a selector to the Wikipedia search page allowing the use of external search engines."
* a wider search box. Go to ''Appearance'' and find "Widen the search box in the Vector skin."
* {{myprefs|Search|Completion}}. Spell-correct titles dropped-down from the search box as you type, or not. Or go to {{myprefs|Appearance}} and see "Disable the suggestions dropdown-lists of the search fields".

The search results page can open in a new tab. See {{myprefs|Gadgets}} ''Browsing''
There are also custom user-scripts to make all search results always open in a new tab. (See the scripts available in ''[[#See also|See also]]''.)<!--
--><section begin=Redirects /><section end="User preferences" />

To hide/opt-out the search results snippets from sister projects, go to {{myprefs|Gadgets|Appearance}} and see "Do not show search results for sister projects on the search results page".

== Tips and tricks ==

=== Searching within a page ===
The internal search engine cannot locate occurrences of a string within the page you are viewing but browsers can usually do this with {{keypress|Ctrl|F}}, or {{keypress|Command|F}} on a Mac.

=== Search Wikipedia from any web page ===
To get Wikipedia search results while on any ''[[web page]]'', you can temporarily set your web browser's search box to become a Wikipedia search search box, even though you're on another web site; see ''[[Help:Searching from a web browser]]''. This trick removes the need to first navigate to Wikipedia from a web page, and {{em|then}} do the search or navigation. It is a temporary change, and then you put it back to your preferred web-search engine.

You can just drag items on the page the name up to the web browser search box {{em|while on any web site}}, even in the lower sections of a Wikipedia page, where no search box is immediately available.

You can reach all twelve [[WP:SISTER|sister projects]] the same way by using interwiki prefixes in the web browser's search box. For example, you can go straight to a [[Wiktionary]] entry by using the prefix '''wikt:''' ''from your web-search box''.<!--
--><section end="Other uses" /><section begin="User preferences" />

== Other search tools ==

Other search tools include
* your own browser, to search the current page only. Try {{keypress|Ctrl|F}}, {{keypress|F3}}, or {{keypress|Command|F}}.
* the [[Main page]]. It searches other-language Wikipedias.
* search-related templates. {{nomirror|See the [[WP:Nav box|navigation box]] below.}}

Internal search tools:
* [[Special:BookSources|ISBN]]
* [[Special:PrefixIndex|Prefix]]
* and many other [[Special:SpecialPages|SpecialPages]]

{{anchor|grep}} External tools dedicated to Wikipedia Database searches include:
* '''[https://tools.wmflabs.org/grep/index.php?lang=en&wiki=wikipedia&ns=0 Article title search]''': searches page titles using [[regular expression]]s. This search is much slower than standard search. In particular this tool can search for exact [[String (computer science)|strings of characters]], including punctuation and with [[case sensitivity]]. For example the pattern <code>\(&&nbsp;Co\.&nbsp;Ltd\.</code> will find only titles containing <code>(&&nbsp;Co.&nbsp;Ltd.</code> exactly as shown. Regular expressions are precisely defined, and not intuitively obvious.
* '''[https://tools.wmflabs.org/catscan2/catscan2.php CatScan]''': Version 3, about twenty search parameters, three for categories
* '''[http://wikipedia.ramselehof.de/wikiblame.php WikiBlame]''': search for text in the revision history of a page
* '''[https://tools.wmflabs.org/sigma/usersearch.py User Contribution Search]''': reports anyone's contributions to a page
* '''[https://tools.wmflabs.org/whichsub/ whichsub]''': finds transcluded templates of a given page which contain a given string.

== If you cannot find what you are looking for ==
If you're looking for a place where wine comes from pronounced "Bordo", you can try searching for a more general article such as "Wine", "Wine regions" (returning "List of wine-producing regions") or other wine types such as "Burgundy" and see if it's mentioned there or follow links (in this case, to "Burgundy wine", which has several mentions of "Bordeaux", and links to "French wine" and "Bordeaux wine"). If you know it's in France, look at "France" or the [[:Category:Cities in France]], from where you can easily find Bordeaux. You can try various things depending upon the particular case; for "Bordo" wine, it's quite likely that the first letters are "bord", so search an article you've landed on for these letters. If you [[Wikipedia:Search engine test|use Google to search Wikipedia]], and click on "cache" at the bottom of any result in the search engine results page, you'll see the word(s) that you searched for highlighted in context.

For an overview of how to find and navigate Wikipedia content, see [[Portal:Contents]]. If you're looking for a straight definition of a word, try our sister project [[:en:wiktionary|Wiktionary]].

If there is no appropriate page on Wikipedia, consider [[Wikipedia:How to start a page|creating a page]], since [[Wikipedia:Introduction|you can edit]] Wikipedia right now. Or consider adding what you were looking for to the [[Wikipedia:Requested articles|Requested articles]] page.

If you have a question, then see [[Wikipedia:Questions|Where to ask questions]], which is a list of departments where our volunteers answer questions, any question you can possibly imagine.

A common mistake is to type a question into the search bar and expect an answer. While some Web search tools support this, the Wikipedia search is a text search only; questions, as such, can be asked at the [[WP:REFDESK|reference desk]] and similar places. A search for ''how do clocks work?'' will return articles with the words ''how'', ''do'', ''clocks'', and ''work'', ignoring the question mark (in practice this can lead to articles answering simple questions).

==={{anchor|Delay}}Delay in updating the search index===
Because people like to see their work in search results, the search engine attempts to update in [[Real-time computing#Near real-time|near real-time]]. Edits made to pages via templates can take a little longer to propagate. If you see the index lagging more than a day or so, [[wmfblog:2013/03/18/how-to-create-a-good-first-bug-report/|report it]]. For other technical issues with the search engine, please leave a message on [[Wikipedia talk:Searching|the talk page]].

== Under the hood ==

To power its search feature, Wikipedia uses [[mw:Help:CirrusSearch|CirrusSearch]], a MediaWiki extension that uses [[Elasticsearch]] to provide enhanced search features.

== Custom search box ==

<inputbox>
type=search
width=90
namespaces=Main**,Portal**,Category**,Help**,
searchbuttonlabel=Search
bgcolor=#cee0f2
break=no
</inputbox>

==See also==
{{Help desk}}

* {{section link|Help:Navigation#Using the search box to navigate}}
* [[Help:Searching from a web browser]]
* [[Help:Searching/Features]]
* [[Help:Searching/feedback]]
* [[MediaWikiWiki:Search]]
* [[Meta:Help:Searching]]
* [[mw:Help:CirrusSearch]]
* [[Wikipedia:Search engine test]]
* {{section link|Wikipedia:WikiProject User scripts/Scripts#Search}}
** [[User talk:The Transhumanist/SearchSuite.js|SearchSuite]]
* [[Wikipedia:Overreliance upon Google]]
* [[Wikipedia:Article name search]]
* [[Wikipedia:External search engines]]
* [[Wikipedia:Manual of Style/List of talk page search boxes]]
* [[Wikipedia:United States government document search tools]]
* [[Wikipedia:WikiProject Geographical coordinates/coordinates search tool]]
* [[Wikipedia:WikiProject User scripts/Scripts/Google search]]
* [[Wikipedia:WikiProject User scripts/Scripts/Multi-NS search]]

; The alternative to searching = browsing
: ''{{aka}}: looking it up''

* [[Wikipedia:Editor's index to Wikipedia]] – an enormous list of the Wikipedia community, intended to help find anything not in the encyclopedia itself.

; Advanced search methods

* [[Help:Searching/Regex]]
* [[Help:Searching/Regex/Sandboxing]]
* {{section link|Wikipedia:Tools#Searching}}
* {{section link|Wikipedia:User scripts/List#Search}}
* [[Wikipedia:Advanced source searching]]
* [[Wikipedia:External search engines]]
* [[Help:Linksearch]]
* [[Wikipedia:PetScan]]
* [[Wikipedia:AutoWikiBrowser/Database Scanner]]

{{RefDesk help icon}}

==Notes==
{{reflist}}

{{Search templates|state=expanded}}

[[Category:Searching in Wikipedia| ]]
[[Category:Reader help]]
[[Category:Wikipedia features]]
[[Category:Wikipedia how-to|Searching]]
[[Category:Wikipedia interface help]]
Anonymous user

Navigation menu