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
      • Menu
      • Modal
      • Notification
        • Alerts
        • Global alert
        • Notifications
      • Pagination
      • Pane
      • Sheet
      • Status indicator
      • Stepper
      • Table
      • Tabs
      • Tags
      • Tiles
      • Timeline
      • Tooltip
      • Tooltip dialog
      • Typography
      • Well
    Table of Contents
    • How to use it
      • Default
      • Type
    • Configuration
    • API
      • Alert

    Alerts

    An Alert provides urgent contextual feedback in response to user action or system activity.


    Table of Contents
    • How to use it
      • Default
      • Type
    • Configuration
    • API
      • Alert

    Used for this
    • For urgent feedback
    • For contextual communication inline with page content
    Not for this
    • For a passive system update, use a Notification instead

    How to use it

    Default

    By default, an Alert will be read first by a screen reader and is persistent until the user dismisses it.

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

    Type

    Types indicate what kind of message is in the alert and help the user understand how to respond. They can be info, warning, error, or success.

    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-notifications
    • Depsnpm install react react-dom styled-components @zendeskgarden/react-theming
    • Importimport { Alert } from '@zendeskgarden/react-notifications'

    API

    Alert

    Prop nameTypeDefaultDescription
    type
    'success' | 'warning' | 'error' | 'info'
    Required

    Applies alert type styles

    Alert.Close

    Extends ButtonHTMLAttributes<HTMLButtonElement>

    Alert.Paragraph

    Extends HTMLAttributes<HTMLParagraphElement>

    Alert.Title

    Extends HTMLAttributes<HTMLDivElement>

    Prop nameTypeDefaultDescription
    isRegular
    boolean

    Applies regular (non-bold) font weight

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