Magic Card
Magic Card supports a gradient or orb surface around ordinary React children.
Practical React example
Give a feature card a cursor-following light treatment without hiding its content.
Before you copy and paste
Match the imported component’s client or server rendering boundary before using the example. Copy components/magicui/magic-card.tsx and its returned support files from the Code tab; preserve the project-relative paths.
Listed package dependencies: motion.
Use the Code tab for the component files and installation instructions, then adapt the imports in this example to your project.
Give a feature card a cursor-following light treatment without hiding its content
// Usage adapted from Magic UI's pinned MIT source.
// Copyright (c) Magic UI. See ./LICENSES.md.
'use client';
import { MagicCard } from "@/components/magicui/magic-card"
export function ComponentExample() {
return (
<MagicCard>
<div className="p-4">
<p>Hello World</p>
<span>Hover me</span>
</div>
</MagicCard>
);
}
Usage example adapted from Magic UI's pinned MIT source. Retain the source licence notices when copying.
Choose one mode and its matching color controls; the mode-specific props are not interchangeable. Keep the parent’s background and contrast consistent with the card treatment.
Customization
- MagicCardBaseProps.children
- Optional; React.ReactNode.
- MagicCardBaseProps.className
- Optional; string.
- MagicCardBaseProps.gradientSize
- Optional; number.
- MagicCardBaseProps.gradientFrom
- Optional; string.
- MagicCardBaseProps.gradientTo
- Optional; string.
- MagicCardGradientProps.mode
- Optional; "gradient".
- MagicCardGradientProps.gradientColor
- Optional; string.
- MagicCardGradientProps.gradientOpacity
- Optional; number.
- MagicCardGradientProps.glowFrom
- Optional; never.
- MagicCardGradientProps.glowTo
- Optional; never.
- MagicCardGradientProps.glowAngle
- Optional; never.
- MagicCardGradientProps.glowSize
- Optional; never.
- MagicCardGradientProps.glowBlur
- Optional; never.
- MagicCardGradientProps.glowOpacity
- Optional; never.
Integration notes
- The visual surface does not make the card a link; provide a real labelled link or button.
- Check touch, reduced motion and the content’s contrast away from the pointer.
Component source: Magic UI documentation . These examples describe the version imported into Rendyn. Upstream APIs may have changed; retain the source licence notices when adapting the code.
Give your agent taste.
The best way to use Rendyn is through MCP. Let your agent find the right component, compare previews and bring the source into your project.
All components are free. Sign up only to connect MCP.