← TechnologyThe essentials of

Max-width: a limit rather than a compulsory width

Publisher: ResumeMaker • 1 source

Published: 23 Oct 2026 08:23 · Updated: 23 Oct 2026 08:23

AI source check: 22 Oct 2026 16:54. This is not editorial approval.

In a few sentences

In brief

max-width limits the used width without independently requiring an element to fill that value. width: 100%; max-width: 70rem illustrates a flexible area with an upper bound.

Useful to know

max-width limits the used width without independently requiring an element to fill that value. width: 100%; max-width: 70rem illustrates a flexible area with an upper bound. [1]

The limit does not centre the box. Alignment is separate, and min-width can impose a different minimum requirement. Check these rules together when content remains too wide.

Sources

For further detail and to check the information:

  1. [1] MDN — CSS max-width ↗