Garden 9 is now available.
The website has been updated to the latest major version. View previous versions
Skip to main content
Design
Components
Patterns
    • Introduction
      • Overview
    • Foundations
      • Bedrock CSS
      • Design tokens
      • Containers
      • Theming
      • Versions
    • Components
      • Accordion
      • Anchor
      • Avatar
      • Breadcrumbs
      • Buttons
      • Chrome
      • Code block
      • Color picker
      • Color swatch
      • Date picker
      • Draggable
      • Drawer
      • Forms
      • Grid
      • Loaders
        • Dots
        • Inline
        • Progress
        • Skeleton
        • Spinner
      • Menu
      • Modal
      • Notification
      • Pagination
      • Pane
      • Sheet
      • Status indicator
      • Stepper
      • Table
      • Tabs
      • Tags
      • Tiles
      • Timeline
      • Tooltip
      • Tooltip dialog
      • Typography
      • Well
    Table of Contents
    • How to use it
      • Default
      • Color
      • Size
    • Configuration
    • API
      • Spinner

    Spinner

    A Spinner appears before a page is loaded to assure a user that the content is on its way.


    Table of Contents
    • How to use it
      • Default
      • Color
      • Size
    • Configuration
    • API
      • Spinner

    Used for this
    • When the content to be loaded is unknown or unpredictable
    Not for this
    • When page content is easily estimated, use a Skeleton instead
    • To indicate a loading state within a component (like menus, inputs, or buttons) use Dots instead

    How to use it

    Default

    Spinners communicate a loading state for an unspecified amount of time.

    Toggle dark mode
    Set primary hue
    Toggle RTL
    Open in CodeSandbox
    Copy code
    View code

    Color

    By default, color is inherited from the parent element. Color can be explicitly set.

    Toggle dark mode
    Set primary hue
    Toggle RTL
    Open in CodeSandbox
    Copy code
    View code

    Size

    By default, the size is inherited from the font size of the parent element. Size can be explicitly set.

    Toggle dark mode
    Set primary hue
    Toggle RTL
    Open in CodeSandbox
    Copy code
    View code

    Configuration

    • Name9.5.3•View source•View on npm
    • Installnpm install @zendeskgarden/react-loaders
    • Depsnpm install react react-dom styled-components @zendeskgarden/react-theming
    • Importimport { Spinner } from '@zendeskgarden/react-loaders'

    API

    Spinner

    Extends SVGAttributes<SVGSVGElement>

    Prop nameTypeDefaultDescription
    color
    string
    'inherit'

    Sets the fill color. Accepts a color variable key (i.e. foreground.primary) to render based on light/dark mode, or any hex value. Inherits the parent's color by default.

    delayMS
    number
    750

    Delays displaying the loader to prevent a render flash during normal loading times

    duration
    number
    1250

    Sets the length of the animation cycle in milliseconds

    size
    string
    'inherit'

    Sets the height and width in pixels. Inherits the parent's font size by default.

    Garden is the design system by Zendesk.
    BlogGitHubVersions
    © Zendesk 2025