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

Design system

  • Overview
    • Design system definitions
    • Overview
    • Theming
    • 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
      • CTA button
      • Icon button
      • Link button
    • Calendar
    • Card
    • Carousel
    • CCD
      • Overview
      • Filter chip
      • Input chip
      • Graphs
      • Metrics
      • Overview
      • Alert
      • Confirmation
      • Standard
    • Divider
    • Education notice
    • EEK rating and range
    • Expansion
      • Overview
      • Checkbox
      • Combobox
      • Date field
      • 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
    • Panel
    • Popover
    • Progress stepper
    • Search field
    • Section header
    • Segmented button
      • Overview
      • Context sheet
      • Focus sheet
    • Signal
    • Snackbar
    • State layer
    • Tab
    • Table
      • Overview
      • Tooltip
      • Tourtip
    • Toggle button group
    • Video player
    • Overview
    • Bulk editing
    • Empty states
    • Filtering
    • Uploading files
      • Overview
      • Text link

Text field

v4.0

Text fields let users enter and submit text.

Stylized artwork of a text field.
Text fieldv4.0

On this page

  • Considerations
  • Anatomy
  • Properties
  • Behavior
  • Screen sizes
  • Specs

Anatomy

Properties

Behavior

Screen sizes

Specs

PreviousText area
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.

    1. Label
    2. Lead icon
    3. Helper text
    4. Prefix
    5. Value
    6. Container
    7. Suffix
    8. Trailing icon

    Label

    Include a label unless another adjacent element already serves that purpose. The label names what the user enters in the field.

    • Use sentence case
    • No ending punctuation
    • Use a noun or noun phrase
    • Aim for 1–3 words

    Value

    The value is the text the user enters and submits with the form. User input replaces any placeholder text after the first character is entered.

    Layout

    There are two layouts available for texty fields, stacked and floating. Stacked labels are above the field and floating labels are inside the field. A floating label animates upward on focus to make room for the value.

    Required/optional fields

    Use an asterisk to indicate a field is required. Display the word “optional” in parentheses next to the field label if the field isn’t required.

    If most fields are required, only indicate the optional fields. If most fields are optional, only indicate the required fields.

    Placeholder text

    Placeholder text, or “ghost text,” gives users a hint about the expected input format. Use realistic examples of what a user might enter, not descriptions of the field.

    Placeholder text disappears when the user starts typing, so don’t use it for instructions or required information.

    • Use sentence case
    • End with ellipsis

    Helper text

    Helper text is placed below the field and informs the user of any requirements or disclaimers. It's shown persistently or on focus. Don't repeat the label.

    • Use sentence case
    • No ending punctuation, unless there's more than 1 sentence
    • Keep to one line

    Character count

    A character counter appears when a character limit is set. It updates in real time as the user types.

    Format as xx / n (with spaces for clarity).

    Size

    There is a small and large size available for text fields. The default is large and is recommended for smaller screens. Avoid mixing different sizes in a form.

    Prefix

    Static text or symbols can be prepended to the input. The prefix clarifies the expected input and removes the need for users to manually enter them. These are useful for values like currency.

    Suffix

    Static text or symbols can be appended to the input. The suffix, or postfix, clarifies the expected input and removes the need for users to manually enter them. These are useful for entering values like dimensions and weight or currencies that use trailing symbols.

    Input formatting

    Input formatting clarifies expectations and formats the input to be easier to read. Slashes, dashes, and spaces are automatically added to the input as the user enters characters.

    Overflow

    Text field values overflow left and right. While focused, the content will shift to keep the cursor in view as the user enters characters. When the field loses focus, the content will scroll to the beginning. Focusing on the field again returns the user to the end of the content.

    Generally, text fields should avoid overflow. Use a Text area field if the value of a field is expected to be longer than a short sentence.

    Active

    The active state is triggered whenever the user interacts with the field. While active, the background color is removed and the border becomes strong.

    Error messages

    Error messages appear below the field when the input doesn't meet the required format or conditions. The error message replaces any existing helper text.

    Keep the tone neutral, don’t blame or scare the user. Clearly inform users the requirements so they know how to fix it.

    • Use sentence case
    • No ending punctuation
    • Avoid technical language or filler words like “please”, “sorry”, or “oops”

    Read-only

    Users cannot focus on or change read-only fields. Their input is derived from other parts of the UI and is intended to be viewable for reference. The input is submitted with the form.

    Disabled

    Users cannot focus on or change disabled fields. Their availability depends on certain requirements. No value will be submitted from disabled fields.

    Clearing input

    The clear button appears by default as a trailing icon while the field is focused and has one or more characters entered.

    Small

    Text fields span the full width of the screen on compact screens.

    Medium and large

    Text fields are aligned to the grid up to their max width on larger screens. Avoid allowing text fields to span the entire width of the page on large screens.

    A text field diagram is shown with 8 elements numbered: 1. Label, 2. Lead icon, 3. Helper text, 4. Prefix, 5. Value, 6. Container, 7. Suffix, 8. Trailing icon.
    Two text fields. A text field with a label built into the component sits above a text field with a section title for a label.
    A text field with a value of “Katherine”.
    Two text fields. A text field with a label above the text field container sits above a text field with the label inside of the text field container.
    Two text fields in both label layouts. The first has a required label with “Address*”. The second has an optional field with “Address (optional)”.
    Three text fields. The first and last text fields have values entered, and the middle one has placeholder text.
    A text field with placeholder text.
    A text field with character counts.
    Two text fields. A text field with a 40px height sits above a text field with a 48px height.
    A ‘Price’ text field with a ‘$’ prefix.
    Two text fields. A ‘Height’ text field with a ‘centimeter’ suffix sit above a ‘Weight’ text field with a ‘kilogram’ suffix.
    Two text fields. A ‘Credit card’ text field with pre-determined formatting sits above a ‘Social Security Number’ text field with pre-determined formatting.
    Text fields with both stacked and floating examples showing text overflow on both sides.
    A form field in the focused state.
    Two ‘Zip code’ text fields  - one label sitting inside the text field container, and one sitting above - with an error message.
    A text field that is read-only.
    A text field in the disabled state.
    Two ‘Street address’ text fields  - one label sitting inside the text field container, and one sitting above - with a clear icon trailing button.
    Text fields sit on a ‘Shipping address’ form on the eBay mobile app. The text fields span the full width on compact screens.
    Text fields sit on an eBay account page on a larger screen. The text fields span full width to the right of a menu panel.
    A text field is shown with specs. The padding on the left and right of the text field container is 16px. The space between the label and container is 4px. The space between the container and helper text is 8px.

    Considerations

    Performant

    Forms allow users to complete fields effortlessly.

    Accessible

    Anyone, no matter their abilities, can complete forms.

    Dynamic

    Forms provide dynamic feedback so users can correct errors quickly and confidently.

    • CSS
    • Marko
    • React