1. Backgrounds
  2. background-repeat

Backgrounds

background-repeat

Handy classes for deciding how an element's background image tiles and repeats.

ClassStyles
bg-repeat
background-repeat: repeat;
bg-repeat-x
background-repeat: repeat-x;
bg-repeat-y
background-repeat: repeat-y;
bg-repeat-space
background-repeat: space;
bg-repeat-round
background-repeat: round;
bg-no-repeat
background-repeat: no-repeat;

Examples

Getting started

Reach for the bg-repeat utility when you want the background image tiled across both the vertical and horizontal axes.

<div class="bg-[url(/img/clouds.svg)] bg-center bg-repeat ..."></div>

Tiling side to side

Reach for the bg-repeat-x utility when the background image should tile only along the horizontal axis.

<div class="bg-[url(/img/clouds.svg)] bg-center bg-repeat-x ..."></div>

Tiling top to bottom

Reach for the bg-repeat-y utility when the background image should tile only along the vertical axis:

<div class="bg-[url(/img/clouds.svg)] bg-center bg-repeat-y ..."></div>

Avoiding cut edges

Reach for the bg-repeat-space utility so the background image tiles neatly without any clipping:

<div class="bg-[url(/img/clouds.svg)] bg-center bg-repeat-space ..."></div>

Avoiding cut edges and gaps

Reach for the bg-repeat-round utility to tile the background image without clipping, stretching each tile as needed so no gaps appear:

<div class="bg-[url(/img/clouds.svg)] bg-center bg-repeat-round ..."></div>

Turning tiling off

Reach for the bg-no-repeat utility to stop a background image from tiling altogether:

<div class="bg-[url(/img/clouds.svg)] bg-center bg-no-repeat ..."></div>

Adapting per screen

Pair a background-repeat utility with a breakpoint variant such as md: so the rule kicks in only from medium-width screens on upward:

<div class="bg-repeat md:bg-repeat-x ...">  <!-- ... --></div>

Dig deeper into how variants work over in variants documentation.

Copyright © 2026 Breezel, Inc.·Trademark Policy