Pattern Background Generator
This pattern is no longer available
The saved tab session is missing, expired or damaged. Start again to create a new pattern. No default design will be shown as your previous work.
Choose a pattern
Each option produces a repeating CSS gradient pattern without an image file.
Pick a motif (dots, grid, stripes, checkerboard, crosshatch or diagonal lines), choose a background color and a pattern color, and set the spacing. The generator builds a repeating background from CSS gradients, shows a live preview, and gives you a ready-to-paste snippet. Depending on the motif, the output uses background-color, background-image, background-size and background-position. It does not create an image or SVG file.
How to generate a pattern
-
1
Pick a motif
Dots, grid, stripes, checkerboard, crosshatch or diagonal lines.
-
2
Set two colors
A background color for the fill and a pattern color for the gradient lines or shapes.
-
3
Adjust the spacing
Set the repeat spacing from 5 px for a dense texture to 80 px for a more open pattern.
-
4
Check the live preview
The panel updates instantly as you change the motif, colours and size.
-
5
Copy the CSS
Grab the generated CSS and paste it onto any element as its background.
Pure CSS, no image files
Every pattern here is drawn with CSS gradients on top of a solid background-color. There is nothing to host and no extra HTTP request: the whole texture lives in the stylesheet. A dots pattern, for example, looks like this:
.hero {
background-color: #1F2937;
background-image: radial-gradient(#FFFFFF 1px, transparent 1px);
background-size: 20px 20px;
background-repeat: repeat;
}
CSS backgrounds repeat by default. The generated size and position values are chosen to align each motif as it repeats, though rendering can vary slightly with browser zoom and fractional device pixels. Change the spacing value to make the texture denser or more open.
What each motif is made of
| Motif | Built from | Good for |
|---|---|---|
| Dots | A repeating radial-gradient |
Tech pages, dashboards, modern UI |
| Grid | Two linear-gradient lines crossing |
Graph-paper feel, whiteboards, planners |
| Dense stripes | A 45-degree repeating-linear-gradient |
Barber-pole accents, playful sections |
| Checkerboard | Four angled linear-gradient layers |
Retro UI, transparency-style backdrops |
| Crosshatch | Two crossed repeating-linear-gradients |
Sketch and print texture, editorial |
| Spaced diagonal lines | One 45-degree repeating-linear-gradient |
Warning states, striped awnings, sport |
Color and contrast tips
- Keep the contrast low for backgrounds. A pattern color close to the background color usually reads as a subtle texture. High contrast can compete with the page content.
- Match your brand. Use a brand color as the pattern color instead of plain gray so the texture fits the surrounding design.
- Dark mode. Try a dark background color and a slightly lighter pattern color. Strong contrast can look noisy on a large dark surface.
- Check text against both colors. If text sits over the pattern, test its contrast against the background color and the pattern color wherever either can appear beneath a glyph. This generator previews the pattern but does not perform a WCAG contrast audit.
Where to use it
- Hero and section backgrounds that need a little texture without an image.
- Cards and panels in a dashboard, where a faint grid or dots adds structure.
- Empty states and placeholders, where a checkerboard reads as neutral.
- Print-style layouts and slides that call for a graph-paper or crosshatch feel.
Because the pattern is CSS rather than a separate background asset, it does not add an image request. You can also adjust its gradient, size and position values later in browser developer tools.
Frequently Asked Questions
No. The output is CSS made from a background color and one or more gradients, with size or position declarations where the motif needs them. You copy the CSS and paste it onto an element. There is no image or SVG file to download or host.
CSS backgrounds repeat by default. The generated size and position values align the layers for the selected motif. Browser zoom and fractional device pixels can sometimes make a repeated edge look slightly different, so check the pattern at the sizes where you will use it.
A low-contrast pattern is usually less distracting, but that alone does not prove readable text. Check the text color against every underlying color it can overlap. For dense text, a plain background is often easier to verify.
The colors are hex values in the CSS. Edit background-color and the color values inside the gradients, or regenerate the pattern here and copy the new snippet.
Related Tools
HEX Color Picker
Pick or enter a HEX colour and get RGB, HSL, approximate CMYK, relative luminance and contrast ratios against white and black.
ASCII Table Reference
Full ASCII table from 0 to 127 with decimal, hex, octal, binary, standard names and HTML numeric-reference notation, including NUL, LF and DEL.
Color Palette Generator
Generate monochromatic, analogous, complementary, triadic or tetradic color palettes from a base HEX color and export copy-ready CSS variables.
FPS Counter
Measure browser FPS with requestAnimationFrame, smoothing, min/max frame rate, warnings and an optional graph. Runs locally with no upload or API.
JSON Formatter
Paste JSON to pretty-print with 2 or 4 spaces, minify it to compact output, or run a quick syntax check before copying the result.
Phone Validator
Validate phone numbers by country, detect the region and type, and normalize valid numbers to E.164, international, national and RFC 3966 formats.