Flex-wrap
The CSS flex-wrap property specifies whether flex items remain on one line or wrap onto multiple lines.
Web Design Playground
A CSS flexbox property that determines whether flex items stay on one line or wrap onto multiple lines.
- How it is used
- Controls whether flex items stay in one row or column or wrap into multiple lines in flexible layouts.
- How deep it goes
- Defines three values and explains default shrinking and cross-axis placement, without detailing browser layout algorithms.
- Examples
- Shows horizontal-axis arrangements for all three values and a liquid-to-flexible-layout conversion, with interactive Playground practice.
- What you can do after
- Operate/configure it on a flex container to create multiple rows or columns when items need more room.
Web Design Playground, Second Edition
The CSS flex-wrap property specifies whether flex items are forced onto one line or can wrap onto multiple lines.
- How it is used
- Controls whether Flexbox items remain on one line or wrap into multiple rows or columns.
- How deep it goes
- Defines three values and contrasts wrapping with item shrinking, but defers detailed multi-line alignment to align-content.
- Examples
- Uses nowrap, wrap, and wrap-reverse in a flex container, with an interactive comparison and a figure showing their effects.
- What you can do after
- Apply it via CSS to choose whether flex items stay together or form additional rows or columns.
Read how Web Design Playground, Second Edition explains flex-wrap →
CSS in Depth, Second Edition
The CSS flex-wrap property specifies whether flex items remain on one line or wrap onto additional lines or columns.
- How it is used
- Controls whether flex items remain in one line or move into additional rows or columns when the container cannot contain them.
- How deep it goes
- Defines three values and explains overflow, flex-shrink interaction, and height constraints for column wrapping.
- Examples
- Uses nowrap, wrap, wrap-reverse, and flex-flow: column wrap as concrete declarations.
- What you can do after
- Apply wrapping rules to flex containers and predict when items form new rows or columns.
Also covered in
What to know first
- flexboxFlexbox is a CSS one-dimensional layout model for arranging, sizing, aligning, and distributing items along a row or column.
Related concepts
- flex-flowconfigured by · The CSS flex-flow property is a shorthand that sets a flex container's flex-direction and flex-wrap properties.
- flexboxconfigures · Flexbox is a CSS one-dimensional layout model for arranging, sizing, aligning, and distributing items along a row or column.
- overflowaddresses · Content overflow is the condition in which content extends beyond the bounds of its containing box or viewport.
- flex containerconfigures · A flex container is an element whose children are laid out as flex items according to the CSS Flexible Box Layout model.
- mainused by · The HTML main element identifies the dominant content of a document or application view, excluding shared navigation and peripheral content.
Questions about flex-wrap
What is flex-wrap?
The CSS flex-wrap property specifies whether flex items remain on one line or wrap onto multiple lines.
Which Manning books explain flex-wrap?
Web Design Playground, Web Design Playground, Second Edition and CSS in Depth, Second Edition.
What should I know before learning flex-wrap?
Manning books that teach flex-wrap usually introduce flexbox first.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.


