Menu
×
   ❮     
HTML CSS JAVASCRIPT SQL PYTHON JAVA PHP HOW TO W3.CSS C C++ C# BOOTSTRAP REACT MYSQL JQUERY EXCEL XML DJANGO NUMPY PANDAS NODEJS R TYPESCRIPT ANGULAR GIT POSTGRESQL MONGODB ASP AI GO KOTLIN SASS VUE DSA GEN AI SCIPY AWS CYBERSECURITY DATA SCIENCE
     ❯   

HTML <search> Tag


Example

Surround the search form with a search element:

<search>
  <form>
    <input name="fsrch" id="fsrch" placeholder="Search W3Schools">
  </form>
</search>
Try it Yourself »

Definition and Usage

The <search> tag is used to specify that here comes a set of elements that is related to search.

Elements inside a <search> elements can typically be form elements used to perform a search.

Note: The <search> element does not render as anything special in a browser. However, you can use CSS to style the <search> element and its content.


Browser Support

Element
<search> Yes Yes Yes Yes Yes

Global Attributes

The <search> tag also supports the Global Attributes in HTML.


Event Attributes

The <search> tag also supports the Event Attributes in HTML.



Related Pages

The <form> Tag.

The <input> Tag.


Default CSS Settings

Most browsers will display the <search> element with the following default values:

Example

search {
  display: block;
}
Try it Yourself »