CSS Flexbox and Grid generator previews real browser layouts while you adjust alignment, wrapping, spacing and columns.
Export plain CSS or literal Tailwind arbitrary-property classes. No account, external editor or upload is required.
How to use
- Choose Flexbox or Grid and adjust the item count and gap.
- Set direction and alignment, or fixed columns and auto-fit minimum width.
- Resize the preview in your browser and copy CSS or Tailwind classes.
Frequently asked questions
Is the preview a real CSS layout?
Yes. The browser lays out real elements using the same values exported as CSS.
Can Grid fit columns automatically?
Yes. Auto-fit uses repeat and minmax, with a minimum bounded by the container width to avoid a narrow-screen overflow.
Do Tailwind exports need custom spacing tokens?
No. The output uses arbitrary properties with pixel values. Keep those class strings literal in your scanned source.
Does it generate an entire webpage?
No. It exports the parent layout. Child content, typography, breakpoints and application behavior remain your responsibility.
Flex direction and wrapping
Flexbox handles one main axis. Switching direction changes that axis; justify-content and align-items operate along different axes.
Grid tracks and child sizing
Fixed columns share the available space with minmax(0, 1fr). Auto-fit responds to available width. Use min-width: 0 on children so long content can shrink.
