Skip to content
Material Design 3
Main Navigation
v3
v2
v1

English

简体中文
繁體中文
Español
Français
Русский
Português – Brasil
Deutsch
日本語
한국어
Italiano
Polski
Türkçe
čeština
magyar

English

简体中文
繁體中文
Español
Français
Русский
Português – Brasil
Deutsch
日本語
한국어
Italiano
Polski
Türkçe
čeština
magyar

Appearance

Sidebar Navigation

Foundations

Accessibility

Overview: Principles

Overview: Assistive technology

Designing: Overview

Designing: Color contrast

Designing: Structure

Designing: Flow

Designing: Elements

Writing and text: Best practices

Writing and text: Text truncation

Writing and text: Text resizing

Building for all: User needs

Building for all: Co-design

Content design

Overview

Alt text

Global writing: Overview

Global writing: Word choice

Notifications

Style guide: UX writing best practices

Style guide: Word choice

Style guide: Grammar and punctuation

Customizing Material

Devices

Watches: Overview

Watches: Foundations

Watches: Styles

Watches: Layout

XR

Design: Overview

Design: Interaction

Design: Layout

Design: Accessibility

Components: Overview

Components: App bars

Components: Dialogs

Components: Nav bar

Components: Nav rail

Components: Toolbars

Design tokens: Overview

Design tokens: How to use tokens

Interaction

Gestures

Inputs

Selection

States: Overview

States: State layers

States: Applying states

Layout

Overview: Overview

Overview: Parts of layout

Overview: Adaptive design

Scaffold: Overview

Scaffold: Bars

Scaffold: Rails

Scaffold: Panes

Grids & spacing: Overview

Grids & spacing: Grids

Grids & spacing: Spacing

Grids & spacing: Density

Breakpoints: Overview

Breakpoints: Compact

Breakpoints: Medium

Breakpoints: Expanded

Breakpoints: Large & extra-large

Bidirectionality & RTL

Canonical examples: Overview

Canonical examples: Feed

Canonical examples: List-detail

Canonical examples: Supporting pane

Usability: Overview

Usability: Applying M3 Expressive

Material A-Z

Styles

Color

Color system: Overview

Color system: How the system works

Color roles

Color schemes

Choosing a scheme

Static: Baseline

Static: Custom brand

Dynamic: Choosing a source

Dynamic: User-generated source

Dynamic: Content-based source

Advanced: Overview

Advanced: Apply colors

Advanced: Define new colors

Advanced: Adjust existing colors

Color resources

Elevation: Overview

Elevation: Applying elevation

Elevation: Tokens

Icons: Overview

Icons: Designing icons

Icons: Applying icons

Motion

Motion physics system: How it works

Motion physics system: Specs

Easing and duration: Applying easing and duration

Easing and duration: Tokens & specs

Transitions: Transition patterns

Transitions: Applying transitions

Shape: Overview & principles

Shape: Corner radius scale

Shape: Shape morph

Spacing: Overview

Spacing: Applying spacing

Spacing: Tokens

Typography: Overview

Typography: Fonts

Typography: Type scale & tokens

Typography: Applying type

Typography: Editorial treatments

Components

App bars: Overview

App bars: Specs

App bars: Guidelines

App bars: Accessibility

Badges: Overview

Badges: Specs

Badges: Guidelines

Badges: Accessibility

Buttons

All buttons

Button groups: Overview

Button groups: Specs

Button groups: Guidelines

Button groups: Accessibility

Buttons: Overview

Buttons: Specs

Buttons: Guidelines

Buttons: Accessibility

Extended FABs: Overview

Extended FABs: Specs

Extended FABs: Guidelines

Extended FABs: Accessibility

FAB menu: Overview

FAB menu: Specs

FAB menu: Guidelines

FAB menu: Accessibility

FABs: Overview

FABs: Specs

FABs: Guidelines

FABs: Accessibility

Icon buttons: Overview

Icon buttons: Specs

Icon buttons: Guidelines

Icon buttons: Accessibility

Segmented buttons: Overview

Segmented buttons: Specs

Segmented buttons: Guidelines

Segmented buttons: Accessibility

Split button: Overview

Split button: Specs

Split button: Guidelines

Split button: Accessibility

Cards: Overview

Cards: Specs

Cards: Guidelines

Cards: Accessibility

Carousel: Overview

Carousel: Specs

Carousel: Guidelines

Carousel: Accessibility

Checkbox: Overview

Checkbox: Specs

Checkbox: Guidelines

Checkbox: Accessibility

Chips: Overview

Chips: Specs

Chips: Guidelines

Chips: Accessibility

Date & time pickers

Date pickers: Overview

Date pickers: Specs

Date pickers: Guidelines

Date pickers: Accessibility

Time pickers: Overview

Time pickers: Specs

Time pickers: Guidelines

Time pickers: Accessibility

Dialogs: Overview

Dialogs: Specs

Dialogs: Guidelines

Dialogs: Accessibility

Divider: Overview

Divider: Specs

Divider: Guidelines

Divider: Accessibility

Lists: Overview

Lists: Specs

Lists: Guidelines

Lists: Accessibility

Loading & progress

Loading indicator: Overview

Loading indicator: Specs

Loading indicator: Guidelines

Loading indicator: Accessibility

Progress indicators: Overview

Progress indicators: Specs

Progress indicators: Guidelines

Progress indicators: Accessibility

Menus: Overview

Menus: Specs

Menus: Guidelines

Menus: Accessibility

Navigation

Navigation bar: Overview

Navigation bar: Specs

Navigation bar: Guidelines

Navigation bar: Accessibility

Navigation drawer: Overview

Navigation drawer: Specs

Navigation drawer: Guidelines

Navigation drawer: Accessibility

Navigation rail: Overview

Navigation rail: Specs

Navigation rail: Guidelines

Navigation rail: Accessibility

Radio button: Overview

Radio button: Specs

Radio button: Guidelines

Radio button: Accessibility

Search: Overview

Search: Specs

Search: Guidelines

Search: Accessibility

Sheets

Bottom sheets: Overview

Bottom sheets: Specs

Bottom sheets: Guidelines

Bottom sheets: Accessibility

Side sheets: Overview

Side sheets: Specs

Side sheets: Guidelines

Side sheets: Accessibility

Sliders: Overview

Sliders: Specs

Sliders: Guidelines

Sliders: Accessibility

Snackbar: Overview

Snackbar: Specs

Snackbar: Guidelines

Snackbar: Accessibility

Switch: Overview

Switch: Specs

Switch: Guidelines

Switch: Accessibility

Tabs: Overview

Tabs: Specs

Tabs: Guidelines

Tabs: Accessibility

Text fields: Overview

Text fields: Specs

Text fields: Guidelines

Text fields: Accessibility

Toolbars: Overview

Toolbars: Specs

Toolbars: Guidelines

Toolbars: Accessibility

Tooltips: Overview

Tooltips: Specs

Tooltips: Guidelines

Tooltips: Accessibility

On this page

Search: Guidelines ​

Search lets people enter a keyword or phrase to get relevant information


When focused, a search bar can show a list of search suggestions. As text is entered, search results appear.

Usage ​

Search helps people find information quickly.

Use search for products with many items to manage, such as files or messages.

Mobile UI shows a search bar at the top of a message inbox.
Search helps people find information in large inboxes like messages or emails

Different ways to search ​

The search entry point is dependent on a product's needs, and should be easy to find:

  • Search barThe search bar is a persistent and prominent search field at the top of the screen.: Use to search contents in a specific view, like Search your messages
  • Search app barSearch app bars provide an emphasized entry-point to open search.More on search app bars: Use this app barApp bars contain page navigation and information at the top of a screen.More on app bars variant when search is the primary, global function
  • Search icon buttonIcon buttons help people take minor actions with one tap.More on icon buttons: Use when search is a secondary action or not the main focus
A mobile app with a search bar below the page title.
Add a search bar below a title to search specific content
A mobile app with a search app bar.
For global search, use a persistent search app bar, integrated into an app bar
A mobile app with a magnifying glass icon on the leading side of the app bar.
Use a search icon button when search is a secondary action

Focused search

When a search entry point is selected, it opens focusedA focused state communicates when a user has highlighted an element, using an input method such as a keyboard or voice.More on focused state search.

  • Search suggestions can appear before text is entered
  • Search results can show as someone is typing or after a search is executed
  • Individual elements maintain their own interaction statesStates show the interaction status of a component or UI element.More on states when search is focused

More on search states

Focused search with a list of suggestions on a mobile screen.
When focused, a search bar expands to show search suggestions or results in a list

If search is the primary action, focused search can be a standalone destination reached from a navigation barNavigation bars let people switch between UI views on smaller devices.More on navigation bars.

Focused search on a mobile screen with a list of suggested contacts.
Focused search can be a standalone destination, reached by selecting an item in a navigation bar

Search suggestions & results

Search suggestions and results both appear in a listLists are continuous, vertical indexes of text and images.More on lists component by default.

To help people find information quickly, consider adding variety and context, such as:

  • Leading icons related to suggestions
  • Category labels, like Recent, Contacts, or Suggestions
  • Avatars or other high-priority items
  • Filter chips to narrow down results
Search with suggestions organized in a column, ending with a row of 5 contact avatars with names.
Include high-priority items like avatars in search suggestions or results

Gaps

Use gaps to separate a list of suggestions or results into groups.

More on using gaps in lists

A gap separates the location and calendar list items from people and pets avatars.
To separate list items into distinct groups, use a gap

Placement ​

A search bar is typically placed at the top of a screen to remain prominent and accessible. Its location depends on whether search is the primary focus of a product or a secondary action.

Mobile UI with a search bar directly below a Settings headline.
A search bar can be the primary focus of a page
Mobile UI with a search bar centered at the top of the screen, above a row of Favorites avatars.
Search bars should usually be placed at the top of the content
A photos app with a search icon.
Search can be a secondary action

Focused search layouts

When focused, search suggestions and results appear in a list below the search bar.

There are two layout options:

  • Docked opens a list below the search bar, with a scrim covering main content
  • Full-screen expands to fill the screen

More on adaptive design

Tablet UI shows a list of search results docked below the search bar.
Docked layout on a tablet
Mobile UI shows a list of search results filling the screen.
Full-screen layout on mobile

Anatomy ​

6 elements of search.
  1. Search bar container
  2. Leading icon
  3. Supporting text
  4. Avatar or trailing icon (optional)
  5. Input text
  6. Container for search suggestions or results

Search bar container

In the contained style, the search bar container remains the same shape in both the unfocused and focused states. Avoid changing the container behavior.

The container's margins should be:

  • Unfocused: 24dp
  • Focused: 12dp

In the divided (baseline) style, a divider separates the search bar and results.

Side-by-side comparison of a search container in unfocused and focused states.
Search bar containers have persistent, rounded corners

Container color

Search bars use the surface container high color roleMaterial has 26 standard color roles organized into six groups: primary, secondary, tertiary, error, surface, and outline.More on color roles. This role applies when the screen background is white or a tonal surface color, ensuring the container has clear contrast.

2 mobile UIs show search bars on white and tonal backgrounds.
Search bars use surface container high to provide clear contrast

Avoid using a surface container high color on a surface container background. This can cause the search bar to blend in, making it difficult for people to find.

To ensure proper contrast, use surface container roles that are more than one step apart.

A “surface container high” search bar on a “surface container” background.
Caution Using a surface container high color on a surface container background reduces contrast and may affect accessibility

Icons & icon buttons

Leading icons

The leading side of a search bar should include either:

  • A navigational icon button, such as a menu or arrow
  • A non-functional search icon
A search bar on a tablet screen contains a non-functional search icon and a trailing avatar.
A search bar can contain a non-functional search icon

Trailing icons

A search bar should have one or two trailing icons or icon buttons.

Trailing actions can include:

  • Additional modes of searching like voice search
  • A separate high-level action such as current location or profile
  • An overflow menu
  • A decorative search icon
A search bar with 2 trailing icon buttons: a microphone and an overflow menu.
Use a maximum of two trailing icons
A search bar with a trailing microphone icon and avatar.
Combine an avatar with up to one other trailing icon button
Focused search with a trailing x icon to clear input text.
Focused search can show an optional clear icon to remove input text

Text

Hinted search text

Provide a short description of the information people can search, like Search replies or Search your messages.

Input text

When a person starts typing, the hinted text is replaced with the input text.

Hinted search text is replaced when a search query is entered

Adaptive design ​

The search bar position and alignment should scale with the layout, and stay close to the searchable content.

In most cases, a search bar should:

  • Stay in its pane and scale in width accordingly
  • Internal elements anchor to the left and right as the parent container scales

More on applying layout

Keep the search bar close to the content a person can search

Focused search

When focused, search can switch between showing suggestions or results in a:

  • Docked layout: Best for mediumWindow widths from 600dp to 839dp, such as a tablet or foldable in portrait orientation.More on medium breakpoints and expandedWindow widths 840dp to 1199dp, such as a tablet or foldable in landscape orientation, or desktop.More on expanded breakpoints windows
  • Full-screen layout: Default for compact breakpointsWindow widths smaller than 600dp, such as a phone in portrait orientation.More on compact breakpoints

More on search layouts

Search suggestions in docked and full screen layouts.
  1. A docked layout on a large screen
  2. A full-screen layout, the default for compact screens

Search suggestions or results should swap from full-screen in compact windows to docked in larger breakpointsBreakpoints are opinionated window sizes where a layout changes to match available space, device conventions, and ergonomics (previously window size classes).More on breakpoints.

Search suggestions and results should adapt to fit different window sizes

Behavior ​

Focused search ​

When a search bar is selected, search becomes focused and can:

  • Show historical suggestions before typing
  • Show suggestions or results as someone is typing
  • Wait to show suggestions or results until a search is queried

The back icon releases focus, dismisses any suggestions or results, and returns the search bar to its original state.

When focused, a list of search suggestions can appear
Focus is released when the back icon is selected

Scroll

Depending on needs, a search bar can:

  • Scroll away with content, then reappear when a person begins scrolling up
  • Remain fixed at the top of the screen
A search bar can scroll up with content, then reappear when a person scrolls down

Search results

To execute a search, a person can:

  • Type a query and press Enter
  • Select a suggestion or result without querying a search

Search results appear in a listLists are continuous, vertical indexes of text and images.More on lists below the bar, and scroll beneath the bar.

For accessibility, focused search needs a clear status indicator that it's searching content, like a search icon or Results label. More on search accessibility

“Peanut” is the entered search query and the first suggestion in the list.
Show search results in a compact, organized list, with an indicator like Quick results

When search results are queried, the input text should remain visible, but not in focus.

Search suggestions and results display in a list, and the input text remains visible

Predictive back

On Android, predictive back allows a person to swipe left or right on search.

  • Search detaches from the screen edge to signal the full-screen layout will minimize
  • The previous screen is revealed in a preview

More predictive back design guidance

The search surface and content scale back in the direction of the gesture
Pager
Previous pageSearch: Specs
Next pageSearch: Accessibility

Released under the Apache 2.0 or CC BY 4.0

Copyright © 2018-Present Google

https://m3.material.io/components/search/guidelines

Released under the Apache 2.0 or CC BY 4.0

Copyright © 2018-Present Google