Glitch Text

Interactive canvas-based text with sticky glitch effect that responds to cursor movement

glitch-text-tw

Customize

80
250
-3
1.5

Props

NameTypeDefaultDescription
textstring"Glitch Text"Text to display. Use ' | ' to split text into multiple lines.
classNamestring""Additional CSS classes for the container.
colorsstring[]["#00ffff", "#ff00ff", "#ffff00"]Array of hex color strings for the glitch effect layers.
textColorstringundefinedMain text color displayed on top. Defaults to black in light mode, white in dark mode.
fontSizenumber80Font size in pixels.
fontWeightstring"600"Font weight (normal, bold, etc.).
radiusnumber250Interaction radius in pixels. Characters within this distance from the cursor will react.
letterSpacingnumber-1Additional spacing between characters in pixels.
lineHeightnumber1.5Line height multiplier for multi-line text.
textAlign"left" | "center" | "right""center"Horizontal text alignment.
fadeInbooleanfalseEnable fade-in animation for letters on load.
autoFitbooleantrueAutomatically scale font size to fit the container width.