Back to components
ElementMiscFree

Animated Underline Link React component

Text links with underlines that move: a line that slides in from the left and out to the right, opens from the centre, draws as a wave, fills behind the text, sweeps like a highlighter, or pushes an arrow, with a faint resting line so they still read as links.

About the Animated Underline Link component

Animated Underline Link is a text link with an animated hover effect in one of six styles: slide, a line that grows in from the left and leaves to the right, center, a line that opens from the middle, fill, a background that rises behind the text, wave, a wavy line, marker, a highlighter stroke behind the text, and arrow, a sliding line with an arrow that nudges forward.

href and children are required, and every other anchor prop passes through. color sets the line or fill color (the text color by default) and thickness the line width for slide, center and wave. resting keeps a faint underline or a thin marker band visible before hover, so it still reads as a link. external opens it in a new tab with an ↗ and a note for screen readers. Keyboard focus plays the same animation as hover.

When to use it

Use Animated Underline Link for text links in articles, footers, navigation and calls to action, where a plain underline feels flat but a button would be too heavy.

Pick one style per context (for example slide in body text, center in navigation) and keep resting on in body copy so links are recognisable before hover.

Installation

Add the Animated Underline Link component to your project with the shadcn CLI. It lands in components/animated-underline-link.tsx as plain React + Tailwind CSS source you own and can edit.

Install
Copied!
npx shadcn@latest add @reactframe/animated-underline-link

Or copy the source by hand and install its dependencies:

Install
Copied!
npm install motion clsx tailwind-merge

Related components

Image Shape Mask
Free
Toggle Price Counter
Free
Typography Prose
Free
Ripple Click Effect
Free
Icon Swap Toggle
Free
Toast Stack
Free