Skip to content

CSS page-break-before Property

The page-break-before property defines a page break before an element.

WARNING

The page-break-before property is replaced by the break-before property.

Generally, page breaks are applied to paged media such as printed books or documents. Once a page break occurs, the current layout ends, and remaining content flows to the next page. This behavior is commonly seen in PDF documents.

The page-break-before property lets you specify whether the following content should start on a left or right page. You can use the CSS @media rule to define break styles for printed documents.

Initial Valueauto
Applies toBlock-level elements.
InheritedNo.
AnimatableNo.
VersionCSS2
DOM Syntaxobject.style.pageBreakBefore = "left";

Syntax

CSS page-break-before syntax

css
page-break-before: auto | always | avoid | left | right | recto | verso | initial | inherit;

Use the code example below to define page break before the element:

CSS page-break-before code example

css
@media print {
  h2 {
    page-break-before: right;
  }
}

Values

ValueDescription
autoAllows automatic page breaks before the element.
avoidPrevents a page break from occurring before the element.
alwaysForces a page break to occur before the element.
leftInserts a page break before the element so that the next page is formatted as a left-hand page.
rightInserts a page break before the element so that the next page is formatted as a right-hand page.
rectoInserts a page break before the element so that the next page is formatted as a right-hand page (equivalent to right).
versoInserts a page break before the element so that the next page is formatted as a left-hand page (equivalent to left).
initialSets this property to its default value.
inheritInherits this property from its parent element.

Practice

What is the function of the 'page-break-before' property in CSS?

Dual-run preview — compare with live Symfony routes.