
Woven thread background
Backgrounds, Hover
A background for a product’s hero made of a mesh gradient you can see and touch, as in the editor of a design tool: twelve points on a grid of hairlines, each with its own colour, breathing slowly on their own and dragged by the pointer on a spring, with the colour flowing along. The grid fades away when nobody touches it. Minimal style.
A folder that runs on its own: index.html, style.css, script.js and the libraries from a CDN. The React and Vue tabs hold the same demo as a ready component, which switches its animations off when it leaves the page.
<!doctype html>
<!--
"Mesh gradient background" from Animorio · https://animorio.com
License: free on your own sites and your clients’ sites, paid work included.
Not for resale, redistribution, templates or code collections · https://animorio.com/en/license/
-->
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>The mesh gradient background with points to drag</title>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fontsource-variable/mona-sans@5.3.0/wdth.css">
<link rel="stylesheet" href="style.css">
</head>
<body>
<!-- the hero of an invented colour tool, Tinct, over a mesh gradient you can see and touch: a fine grid of curved
lines through twelve control points, each carrying a colour; the points breathe on their own, follow the
pointer on a spring when dragged, and the grid fades away when nobody touches it -->
<main class="stage" data-stage>
<canvas class="field" data-field aria-label="Mesh gradient: drag the points to move the colour" role="img"></canvas>
<span class="grain" aria-hidden="true"></span>
<section class="hero" aria-labelledby="hero-title">
<p class="pill" data-in>
<span class="pill__tag">New</span>
<span class="pill__text">Mesh gradients in Tinct</span>
</p>
<h1 class="title" id="hero-title" data-in>Colour that<br>bends with you</h1>
<p class="hint" data-in data-hint>
<svg viewBox="0 0 16 16" aria-hidden="true"><path d="M8 2.5v11M2.5 8h11M8 2.5 6.2 4.3M8 2.5l1.8 1.8M8 13.5l-1.8-1.8M8 13.5l1.8-1.8M2.5 8l1.8-1.8M2.5 8l1.8 1.8M13.5 8l-1.8-1.8M13.5 8l-1.8 1.8"></path></svg>
<span>Drag the points</span>
<button class="reset" type="button" data-reset>Reset</button>
</p>
</section>
</main>
<script src="https://cdn.jsdelivr.net/npm/gsap@3.15.0/dist/gsap.min.js"></script>
<script src="script.js"></script>
</body>
</html>Change values, colours and text with the controls and watch the animation respond live. Or write in the code yourself. Then download the folder with your changes.
23 values to change
Works with Claude, Claude Code, ChatGPT, Cursor, VS Code, Windsurf, Codex, Gemini CLI
With the Animorio connector, Claude Code, ChatGPT, Cursor or VS Code take it from here, guide included, and fit it into your project. Paste this request:
Take “Mesh gradient background” from Animorio and fit it into my siteThe points sit on a grid of four columns and three rows, in coordinates from 0 to 1, each with one of the four colours from :root. The middle columns are wide apart, so the points do not end up under the headline.
The colour is painted on a small canvas, about 150 pixels across, then stretched over the whole page with high smoothing: for each pixel the average of the points’ colours weighted by a Gaussian of the distance (SOFTNESS), with a touch of light in the middle where the words sit. The blend is so soft that the stretch does not show, and it costs very little.
For each row and column a Catmull-Rom curve, turned into Bézier curves, runs through the points: when a point moves the nearby lines bend with it. On top, the points: a white circle with a shadow and their colour in the middle.
Each point has a position and a velocity and chases its target with a spring (SPRING) and a damping that leaves a hint of bounce (BOUNCE). The target is where it was left plus the breath, two slow waves BREATH seconds long; while dragged it is the pointer.
Every pointer move stamps the time; after GRID_FADE seconds of nothing the grid fades out slowly, and comes back quickly on the first pass. If nobody touches for AUTO_DRAG seconds, a GSAP timeline grabs a point and drags it on its own.
| Name | File | Default | What it changes |
|---|---|---|---|
SOFTNESS | script.js | 0.22 | How far each point’s colour spreads. |
BREATH | script.js | 6 | How many seconds one breath of the points lasts. |
BREATH_AMP | script.js | 0.018 | How much the points move when they breathe (0 stops them). |
SPRING | script.js | 170 | How stiff the points’ spring is. |
BOUNCE | script.js | 0.38 | How much the points bounce when they arrive. |
GRID_FADE | script.js | 2.6 | After how many untouched seconds the grid fades away. |
HANDLE | script.js | 6 | The radius of the points in pixels. |
AUTO_DRAG | script.js | 2.2 | After how many untouched seconds a point drags itself (0 never). |
As the background of the first screen of a design tool, a creative app, a product about colour or a launch: a gradient that invites play without stealing the scene from the headline.
The same mesh on a tall narrow page: the points are picked up with a finger, with a margin wider than the circle, and the page does not scroll while dragging them; the headline goes on two smaller lines.
No breathing, no springs and no points moving on their own: the grid stays faint and visible, dragged points go straight where they are taken, the words are already in place.
GSAP 3.15.0, Mona Sans (font variabile) 5.3.0.
Compressed with gzip, the three demo files weigh 7.1 KB; the libraries: GSAP 28 KB.
Tested on 23 November 2026
Use it in your own projects and in your clients’ projects. Do not resell it or redistribute it as is. GSAP stays under its own Standard license. Full license.
You asked for
We made it for you: it’s in the library, with the preview, the Playground and the code to copy.
An animation you can’t find, or a site to take apart in the journal: tell us which. We pick the next ones from here.
With your account’s email and password.
or with your email
You’re signed in as .
With your account, you can download the zip of every animation and every pack, for free.