# columns

> The `columns` CSS property is a shorthand for setting both `column-width` and `column-count` properties.

## How do I make a responsive multi-column layout with CSS columns?

The shorthand property that combines `column-width` and `column-count` properties, enabling to define both the width and the number of columns in a multi-column layout in a single line. This makes it easier to control the layout's appearance.

- Topic: Columns & Tables
- Type: property
- Browser support: Chrome 50+, Chrome Android 50+, Edge 12+, Firefox 52+, Firefox Android 52+, Safari 9+, Safari iOS 9+

## Example

Wrong:

```css
.articles {
  column-count: 3;
}
```

Right:

```css
.articles {
  columns: 16rem 3;
  column-gap: 2rem;
}
```

With a width and a count, the browser uses at most three columns and only as many as fit at about 16rem each.

## Common mistakes

- Three fixed columns become unreadably narrow on phones.
- A card is cut in half and continues at the top of the next column.

## Key points

- The value combines a minimum width and a maximum count, like '16rem 3', so columns drop on small screens.
- Items that must not split across columns have `break-inside: avoid`.
- Card grids that read left to right use Grid, since columns fill top to bottom.

## Interview questions

### Can I use CSS columns for a masonry layout?

It looks similar, but items flow down each column first, so the reading order goes top to bottom instead of across rows.

### What is the difference between columns and grid?

Columns flow one continuous content stream into columns. Grid places items in rows and columns you define.

## Related cards

- [column-count](https://wonderium.dev/css/column-count.md)
- [column-width](https://wonderium.dev/css/column-width.md)
- [column-gap](https://wonderium.dev/css/column-gap.md)
- [column-span](https://wonderium.dev/css/column-span.md)
- [grid](https://wonderium.dev/css/grid.md)

---

- Level: [CSS](https://wonderium.dev/css.md)
- HTML version: https://wonderium.dev/css/columns
- Last updated: 2026-11-25
