Skip to content
VenusUI
Get started

Glow Border Button

A button with a light that keeps circling its border.

Preview

Installation

npx shadcn@latest add @venusui/glow-border-button

Run this in a project set up with shadcn. If you haven’t set it up yet, run npx shadcn@latest init first.

Files added to your project

Paths use the default shadcn aliases. The CLI follows the aliases in your components.json.

  • @/components/ui/glow-border-button.tsx

Usage

The code behind the preview above.

glow-border-button-demo.tsx

import { ArrowRight } from "lucide-react"

import { GlowBorderButton } from "@/components/ui/glow-border-button"

export default function GlowBorderButtonDemo() {
  return (
    <GlowBorderButton>
      Get early access
      <ArrowRight aria-hidden="true" />
    </GlowBorderButton>
  )
}

API reference

PropTypeDefaultDescription
colors[string, string]violet → skyColors of the circling light. Any CSS colors.

All <button> props. type defaults to "button".

Requirements

  • Tailwind CSS v4. The CLI adds the glow-border-spin keyframes. Works in Server Components.

Customization

  • For a link, copy the markup onto an <a> or your router’s link.
  • Change the size with h-* and the inner px-* padding.

Accessibility

  • A real <button> with a visible focus ring.
  • The light stops with reduced motion; the border stays.

Troubleshooting

The light looks clipped.
The button needs overflow-hidden (set by default); don’t remove it.
Unknown registry "@venusui"
Your shadcn CLI couldn’t find the namespace in the shadcn registry index. Use the latest CLI (npx shadcn@latest), install by URL, or register it with its address: npx shadcn@latest registry add @venusui=https://venusui.com/r/{name}.json.
No components.json found
Run npx shadcn@latest init in your project first.
Loading preview

A heart toggle that pops and bursts when liked, with an optional count.

Loading preview

A button that sends a ripple out from where it was pressed.

Loading preview

A primary button with a light sweep across its surface.