HTML Runner

CSS Flexbox Generator

Explore wrapping, spacing and alignment with an interactive Flexbox layout.

ABCD

How to use CSS Flexbox Generator

Change direction first. Then compare justify-content and align-items while switching between row and column.

Limitations

The sample items have short labels. Test wider content and long unbroken strings in your own layout.

Frequently asked questions

Which axis does justify-content control?

It sets alignment on the main axis, which follows flex-direction.

Test your web code in the live HTML workspace.

Related resources