Skill library

Agent skill Frontend

Magic UI

Build or refine reusable components for a web interface.

  • UI components
  • Animation

Install the skill

Installation method

Run the command from your project root with Node.js and npm.

npx skills@latest add magicuidesign/magicui --skill magic-ui --agent claude-code --yes

Check this file in your project.claude/skills/magic-ui/SKILL.md

Other ways to install
  • Choose an assistant interactively

    npx skills@latest add magicuidesign/magicui --skill magic-ui

    Select your assistant and choose the project installation scope.

    Official instructions

The tested Skills CLI 1.10.0 requires Node.js 22.20 or later. A React project with Tailwind and shadcn configured, a target card and its real controls, and a chosen motion purpose.

View operation manual

What this skill helps with

  • Build or refine reusable components for a web interface.

Good for

  • Component implementation
Task
Add one Magic UI effect to an existing, accessible React card
Inputs
A React project with Tailwind and shadcn configured, a target card and its real controls, and a chosen motion purpose.
Deliverable
A single registry component integrated into the existing card and checked with pointer, keyboard, phone width and reduced motion.
Skill name
magic-ui

Set a scope and verify the actual outcome

An underspecified prompt

Add all the Magic UI effects that make this card look premium.

Multiple interactive visual layers can fight one another, change stacking, or hide focus and meaningful content. The registry command can also install dependencies.

A verifiable workflow

  1. Know the registry alias, generated file and dependency before writing.
  2. The registry code is imported from the actual generated path, with a meaningful native action.
  3. The decorative layer does not obstruct native actions at desktop or mobile widths.

Magic UI operation manual

A single registry component integrated into the existing card and checked with pointer, keyboard, phone width and reduced motion.

A React project with Tailwind and shadcn configured, a target card and its real controls, and a chosen motion purpose.

  1. Choose one effect and preview what the registry will change

    Know the registry alias, generated file and dependency before writing.

    Prompt · Step 1
    Use the installed Magic UI Skill on [target card, motion purpose and React project]. Check the project’s components.json and alias configuration first. Use npx shadcn@latest add @magicui/magic-card --dry-run when supported. If the registry is unavailable, use the official Magic UI setup for this project rather than guessing a URL. Report the destination and dependencies and confirm the requested scope.
  2. Install the approved card and keep the real interaction accessible

    The registry code is imported from the actual generated path, with a meaningful native action.

    Prompt · Step 2
    In [approved project], install @magicui/magic-card using shadcn add and inspect the generated file and dependency diff. Import from the actual destination, style it with existing tokens and keep its real link or button semantic and focusable. Limit the pointer effect to the card. If the motion is distracting under a reduced preference, provide a static visual treatment with readable text and focus.
  3. Operate the finished card in the normal app route

    The decorative layer does not obstruct native actions at desktop or mobile widths.

    Prompt · Step 3
    Open [local preview]. Exercise the card link or button using the keyboard, pointer and a narrow touch viewport. Verify focus is visible, the effect stays in its bounds and the labels still fit. Switch the browser to reduced motion and confirm the static view still works. Show the import path, the real registry dependencies, and the verification outcomes.

Look up verification and troubleshooting

Follow the published guidance in your actual project.

What should I check when the generated import path differs from the example?SKILL.md
Command or reference
shadcn add @magicui/magic-card --dry-run
Examples
Use the actual files produced by shadcn and your project aliases. The common @/components/ui path applies only when the project is configured with that alias and destination.

Troubleshooting and FAQ

What should I check when the generated import path differs from the example?

Use the actual files produced by shadcn and your project aliases. The common @/components/ui path applies only when the project is configured with that alias and destination.