Morph Cursor, animated React component
- Pro
- Motion Effects
- Hover
- Spring
An iPad-style pointer for a panel: a soft dot that melts into the shape of whatever you can press, sits behind it as a highlight while the element leans toward you, and turns into a caret over text. The system cursor is hidden only inside the panel.
Props
| Prop | Type | Default | What it does |
|---|---|---|---|
| icons | MorphCursorIcon[] | DEFAULT_MORPH_ICONS | Icon buttons in the top row, each { id, label, path } with a 24×24 path. |
| buttonLabel | string | "Start a project" | Label of the pill button. |
| inputLabel | string | "Project name" | Accessible name of the text field. |
| defaultInputValue | string | "Spring launch, website and email" | Starting text in the field. |
| cards | MorphCursorCard[] | DEFAULT_MORPH_CARDS | Tiles under the field, each { id, label, gradient }. |
| accent | string | "#0071e3" | Colour of the caret over the field and of the focus rings. |
| onAction | (id: string) => void | — | Called with an icon id, "button" for the pill, or a card id when one is pressed. |
| hint | string | "Move the pointer around." | Caption at the bottom of the panel. An empty string hides it. |
| autoplay | boolean | false | Tours the pointer over every target until someone moves over the panel. |
| className | string | — | Extra classes for the panel. |
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 with your API key
Morph Cursor is a Pro item, so the CLI has to send your API key. Do this once per project:
- Create a key at nexus-ui.com/dashboard/api-key. Copy it straight away: it starts with
nxs_and is shown only once. - In your project root, next to
package.json, create a file named.env.localwith this line, using your own key:NEXUS_API_KEY=nxs_your_key_here
- Open
components.jsonand add this entry inside the outermost braces, next to"aliases". Leave{name}and${NEXUS_API_KEY}exactly as written; the CLI fills them in:"registries": { "@nexus-labs": { "url": "https://www.nexus-ui.com/api/registry/{name}", "headers": { "Authorization": "Bearer ${NEXUS_API_KEY}" } } }
- Create a key at nexus-ui.com/dashboard/api-key. Copy it straight away: it starts with
How Morph Cursor works
A pointer with manners, like the one on an iPad. It's a soft dot until it sits behind it as a highlight, while the element leans a few pixels toward your hand. Over text it becomes a caret. The system cursor is hidden only inside this panel.
The source, the install command and the build prompt come with Pro.
Morph Cursor questions
What is the Morph Cursor, and is it a site-wide custom cursor?
It is a self-contained panel, not a global cursor. Inside it a soft dot melts into the shape of whatever you hover (icon button, pill, card), sits behind it as a highlight while the element leans toward the pointer, and becomes a caret over the text field. The system cursor is hidden only inside the panel.
How do I install it and what does it depend on?
Run `npx shadcn@latest add @nexus-labs/morph-cursor`. It installs framer-motion; the cursor is an absolutely positioned div whose size and radius are animated with Framer Motion springs, with no canvas. It is a Pro component, so it needs a Pro plan and an API key; key setup is on the CLI docs page (/docs/cli).
How do I change the contents of the panel?
Pass `icons` (`{ id, label, path }` with a 24 by 24 SVG path), `buttonLabel`, `inputLabel`, `defaultInputValue` and `cards` (`{ id, label, gradient }`). `onAction` receives an icon id, "button" for the pill, or a card id, and `accent` (default `#0071e3`) colors the caret and focus rings.
Does it work with the keyboard?
Yes. The targets are real buttons and an input with accessible names, and the highlight jumps to whichever one receives keyboard focus (focus-visible) and shows a focus ring. The component does not check prefers-reduced-motion.

