SwiftUI gradient & glow animations

17 examples. Gradient & glow animations built with SwiftUI. Animated gradients, glows, mesh gradients and shimmering borders.

SwiftUI gradient & glow animations: common questions

How do I build gradient & glow animations in SwiftUI?
Pick an example below, copy its prompt (or send it to Claude Code, Cursor or Codex) and your agent builds it in SwiftUI. Each prompt lists the layout, timing and easing, and links a keyframe sheet of the motion. Use withAnimation with a spring, for example .spring(response: 0.35, dampingFraction: 0.8), for most state changes. Reach for matchedGeometryEffect when an element moves between views, PhaseAnimator or KeyframeAnimator for multi-step sequences, and contentTransition(.numericText()) for changing numbers.
How do I animate a gradient?
Animate gradient positions or angles with CSS custom properties (@property), or use a shader for mesh gradients.
How do I make a glowing border?
Mask a rotating conic gradient to the border shape and add a blurred copy behind it for the glow.

Gradient & glow animations in other frameworks

More SwiftUI animations