Nebula Glass Card, animated React component
A frosted glass card floating over a slowly drifting nebula. It tilts toward the pointer on springs with its layers at different depths, a rim light runs round the edge on the pointer's side, and a press dips the card in and flashes the rim before it springs back.
- Free
- Cards
- Hover
- 3D
- Spring
- Scroll
Like Nebula Glass Card? 256 more are in Pro.
Pro unlocks all 256 Pro components, every template and block, and everything we release next. Nebula Glass Card stays free.
Play with it
Move the controls and watch it change. Copy code gives you a snippet with only the props you changed.
Render anywhere
Edge rendering in 28 regions, with previews that land before you finish the sentence.
- Renders
- 12.4k
- Uptime
- 99.98%
- Regions
- 28
Props
| Prop | Type | Default | What it does |
|---|---|---|---|
| eyebrow | string | "Nebula Pro" | Small label above the title. |
| title | string | "Render anywhere" | Card heading. |
| description | string | — | One or two lines under the heading. |
| stats | { label: string; value: string }[] | 3 sample stats | Up to three figures along the bottom. An empty array hides the row. |
| cta | string | "Upgrade" | Button label. An empty string hides the button. |
| onAction | () => void | — | Called when the button is pressed. |
| hues | [string, string, string] | ["#bf5af2", "#0a84ff", "#ff6482"] | Colours for the nebula behind the glass and the rim light. |
| tiltStrength | number | 12 | Maximum tilt in degrees. |
| children | ReactNode | — | Replaces the default body (eyebrow, title, description, stats). |
| hint | string | "Move over the glass, then press it." | Caption under the card. An empty string hides it. |
| autoplay | boolean | false | Sweeps a virtual pointer across the card, pressing now and then, until someone touches it. |
| className | string | — | Extra classes for the root. |
Add it to your project
- 1
Set up your project once
You need a Next.js project with Tailwind CSS and the
@/import alias. In its root folder, run this once. It createscomponents.jsonand thecn()helper insrc/lib/utils.ts:npx shadcn@latest init -d
Starting from nothing? The Quick Start walks through the whole thing.
- 2
Connect the registry
Run this once per project. It writes the Nexus UI entry into
components.jsonfor you:npx shadcn@latest registry add "@nexus-labs=https://www.nexus-ui.com/api/registry/{name}"Type it exactly as shown.
{name}is filled in by the CLI with the component you ask for, so you never replace it.
- 3
Add the component
Run this from your project root. It adds the component, the helpers it imports and its npm packages.
npx shadcn@latest add @nexus-labs/nebula-glass-card
- 4
Check what was added
With a project made as in the Quick Start (a
src/folder), these files land in it:components/nebula-glass-card/index.tsnebula-glass-card.tsx - 5
Copying by hand? Skip the registry
Instead of steps 2 and 3 you can copy the files yourself, with no registry and no API key. Step 1 still applies, so that
cn()exists. Install the packages:npm install framer-motion
Then show the source and create each file at the path it gives:
- 6
Use it in a page
Installing only adds the files. Import the component in a page and render it. The Usage tab on the preview shows a fuller example with props:
// src/app/page.tsx import { NebulaGlassCard } from "@/components/nebula-glass-card"; export default function Page() { return ( <main> <NebulaGlassCard /> </main> ); }
Like Nebula Glass Card? 256 more are in Pro.
Pro unlocks all 256 Pro components, every template and block, and everything we release next. Nebula Glass Card stays free.
About Nebula Glass Card
The Nebula Glass Card is a 3D tilt card with spring physics and luminous edge lighting that responds to cursor position. As the mouse moves across the card, Framer Motion spring transitions rotate it in three dimensions, revealing depth through layered glass surfaces. The border glow tracks cursor proximity using a radial gradient that repositions as the cursor moves, creating a living edge highlight effect. Use it for pricing cards, feature callouts, or team profiles where high-end interactivity signals product polish.
Good for
- Pricing plan cards
- Feature highlight panels
- Team member and advisor profiles
- Product showcase cards