Skip to main contenteBay Playbook
  • Get started
  • Foundations
  • Design system
  • Expressions
  • Resources
  • Articles

Design system

  • Overview
    • Overview
    • Color
    • Dimension
    • Spacing
    • Typography
    • Breakpoints
    • Shadow
    • Shape
    • Opacity
    • Motion
    • Overview
    • Status
    • Accordion
    • Action bar
      • Overview
      • Inline notice
      • Page notice
      • Section notice
    • Avatar
    • Badge
    • Banner
    • Breadcrumb
      • Overview
      • Branded button
      • CTA button
      • Icon button
      • Link button
    • Card
    • Carousel
    • CCD
      • Filter chip
      • Input chip
      • Graphs
      • Metrics
    • Date picker
    • Dialog
    • Divider
    • Education notice
    • EEK rating and range
    • Expansion
      • Checkbox
      • Combobox
      • Dropdown
      • Numeric stepper
      • Password
      • Phone number
      • Radio button
      • Select list
      • Switch
      • Text area
      • Text field
    • Item tile
    • List row
      • Overview
      • Expressive loader
      • Skeleton loader
    • Media container
      • Top navigation bar
    • Pagination
    • Popover
    • Progress stepper
    • Search field
    • Section header
    • Segmented button
      • Overview
      • Context sheet
      • Focus sheet
    • Signal
    • Snackbar
    • Tab
    • Table
      • Tooltip
      • Tourtip
    • Toggle button group
    • Video player
    • Overview
    • Bulk editing
    • File uploading
      • Text link

Search field

v2.1

The search field filters a list using custom characters and keywords.

Search fieldv2.1

On this page

  • Anatomy
  • Options
  • Behavior
  • Screen size
  • Best practices
  • Specs
PreviousProgress stepper
Things.People.Love.
  • Get started
  • Foundations
  • Design system
  • Expressions
  • Resources
  • Articles
  • About eBay Design
  • Careers
  • Press
  • Privacy policy
© 2026 eBay. All rights reserved.

eBay Evo, the eBay trademark, and the eBay logo are the intellectual property of eBay Inc.

    Anatomy

    Options

    Behavior

    Screen size

    Small screens

    Search fields span the full width of the container on smaller screens. The search field should be near the top of the page to ensure there’s enough room for the device keyboard and the first few results to be visible. The screen will scroll to keep the search field in view when receiving focus.

    Medium and large screens

    Medium and large screens across platforms can use the search field inline with other elements, like filter buttons in an action bar.

    Best practices

    Specs

    Two search fields showing icons, placeholder text, and layout variants.
    1. Search icon
    2. Placeholder text
    3. Field container
    4. Trailing accessory
    5. Input text
    6. Clear button

    Size

    Search fields are available in small, medium, and large sizes. The default size is small and the tap target is 48px across all sizes.

    Three search bars at 48px, 40px, and 32px height with same content.

    Placeholder text

    The placeholder text clarifies what content is filtered when searching.

    Search bar with “Search messages” placeholder and voice icon.

    Input text

    The input text contains the characters used to filter a list. Ideally, the list is filtered in real time as each character is typed.

    Search bar with entered text “Input text” and clear (X) button.

    Trailing accessories

    The trailing accessory is optional and provides alternative methods to enter text. The default accessory is a camera button.

    The trailing accessory is replaced with a clear button by default when the field is focused and receives one or more characters.

    Camera icon is replaced by clear (X) button when text is entered.

    Static search icon

    The lead search icon is static and acts as an indicator and affordance of the field’s purpose in place of a label.

    4 different states of a search field where each has a persistent search icon at the beginning.

    Overflow

    Input text overflows horizontally and is masked between the lead and trailing accessories. The cursor remains visible while the field is focused and the input text will adjust in alignment to keep the cursor in view. The input text aligns to the start when the field loses focus.

    Search fields with long input that overflows beyond the visible area.

    Focus state

    Focusing on the search field places the text cursor at the leading edge of the placeholder text. The placeholder text and trailing accessories by default are replaced with a clear button when one or more characters are entered.

    Refocusing on the field places the typing indicator at the end of the input value.

    Top bar with placeholder, bottom bar with typed text and clear button.

    Cancel button

    Place a cancel or back button near the search field in search views or similar contexts where users need a clear option to exit the view. This is essential in native search interfaces to provide a straightforward way for users to navigate away from the search.

    Mobile search showing results for “coltrane” with three John Coltrane vinyl albums and a clear (X) button in the search bar.

    Search button

    Include a search button after the search field when a server request and page refresh are necessary. This approach is particularly useful for large datasets in tables, where real-time searching can slow down performance and degrade the user experience.

    Search bar with suggestions for “sneakers” and matching bold keywords.

    Width

    Search fields have a maximum width of 480px and a minimum width of 200px.

    Search bars shown at 200px and 480px widths with identical structure.
    Mobile native app search with keyboard and vinyl results for "coltrane."

    Native

    Where possible, native platforms use real-time filtering as characters are entered. Native platforms can also leverage a focused search view to reduce unnecessary UI as a search query is entered.

    Mobile web search in eBay Watchlist for "coltrane" with results.

    Web

    Search fields on web platforms filter the list below the field.

    Desktop Watchlist view with inline search for "chair" results.
    Search bar annotated with padding and spacing for icons and content.

    Search icon visibility

    Do keep the lead search icon accessory.

    Search icon remains visible while typing.

    Don’t hide the lead search icon accessory, even when text is entered.

    Search icon hidden while typing.

    Search field height

    Do use a size that matches adjacent inline elements.

    Search field height matches adjacent buttons.

    Don’t use a search field that’s a smaller or larger than adjacent inline elements.

    Search field height misaligned with adjacent buttons.
    • CSS
    • Marko
    • React