---
title: Popover
description: An accessible popup anchored to a button.
author:
  name: imskyleen
  url: https://github.com/imskyleen
---

<ComponentPreview name="base-popover-demo" />

## Installation

<ComponentInstallation name="base-popover" />

## Usage

```tsx
<Popover>
  <PopoverTrigger>Open Popover</PopoverTrigger>
  <PopoverContent>Popover Content</PopoverContent>
</Popover>
```

## Props

<div className="flex flex-row gap-x-3">
  <ExternalLink
    href="https://base-ui.com/react/components/popover"
    text="Docs"
  />
  <ExternalLink
    href="https://base-ui.com/react/components/popover#api-reference"
    text="API Reference"
  />
</div>

### Animate UI Props

#### PopoverContent

<TypeTable
  type={{
    positionerClassName: {
      description: 'The class name to apply to the positioner.',
      type: 'string',
      required: false,
    },
    motionProps: {
      description: 'The props to pass to the motion component.',
      type: "HTMLMotionProps<'div'>",
      required: false,
    },
    popupProps: {
      description: 'The props to pass to the popup component.',
      type: 'typeof PopoverPrimitive.Popup',
      required: false,
    },
    transition: {
      description: 'The transition to use for the popover.',
      type: 'Transition',
      required: false,
      default: '{ type: "spring", stiffness: 300, damping: 25 }',
    },
  }}
/>

## Credits

- We use [Base UI](https://base-ui.com/react/components/popover) for the popover component.
- We take our inspiration from [Shadcn UI](https://ui.shadcn.com/docs/components/popover) for the popover style.
