W3cubDocs

/CSS

column-count

The column-count CSS property breaks an element's content into the specified number of columns.

/* Keyword value */
column-count: auto;

/* <integer> value */
column-count: 3;

/* Global values */
column-count: inherit;
column-count: initial;
column-count: unset;

Syntax

Values

auto
The number of columns is determined by other CSS properties, such as column-width.
<integer>
Is a strictly positive <integer> describing the ideal number of columns into which the content of the element will be flowed. If the column-width is also set to a non-auto value, it merely indicates the maximum allowed number of columns.

Formal syntax

<integer> | auto

Example

HTML

<p class="content-box">
  This is a bunch of text split into three columns
  using the CSS `column-count` property. The text
  is equally distributed over the columns.
</p>

CSS

.content-box {
  column-count: 3;
}

Result

Specifications

Specification Status Comment
CSS Multi-column Layout Module
The definition of 'column-count' in that specification.
Candidate Recommendation Initial definition.
Initial value auto
Applies to Block containers except table wrapper boxes
Inherited no
Media visual
Computed value as specified
Animation type an integer
Canonical order per grammar

Browser compatibility

Feature Chrome Edge Firefox Internet Explorer Opera Safari
Basic support

50

Yes -webkit-

Yes

Yes -webkit-

52

1.5 -moz-

10

11.1

15 -webkit-

3 -webkit-
On display: table-caption Yes Yes 37 Yes Yes Yes
Feature Android webview Chrome for Android Edge mobile Firefox for Android Opera Android iOS Safari Samsung Internet
Basic support Yes 50

Yes

Yes -webkit-

52

4 -moz-

Yes

Yes -webkit-

Yes

Yes -webkit-

?
On display: table-caption Yes ? Yes 37 Yes Yes ?

© 2005–2018 Mozilla Developer Network and individual contributors.
Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
https://developer.mozilla.org/en-US/docs/Web/CSS/column-count