Favorite places of your favorite city
Home
Add to preferred sources on Google

CSS Flexbox Generator

Edit a bounded layout example, see how its axes and items behave, and copy the matching CSS and HTML. The complete download uses the same document as the preview.

Flexbox preview

Container and items

100–1200 px

100–1200 px

0–48 px

0–100 px

0–100 px


Items in source order

Up to 120 UTF-16 code units; text is not interpreted as HTML.

0–10

0–10

−10–10

8–48 px

Preview and code

The HTML fragment needs the CSS. The complete example download uses the same document as the preview, including its document reset and resource policy.

Main: left → right; cross: top → bottom.

Item 1 · Order 0Item 2 · Order 0Item 3 · Order 0

CSS order and reverse settings change visual arrangement, not source, reading, or keyboard order. Move items to change the HTML source order.

Align content has no effect when wrapping is disabled.

Fit changes only the view scale. The sample has fixed border-box dimensions; padding, borders and scrollbars reduce its inner space. System fonts and browser rendering can differ.

Axes and source order

CSS order and reverse settings change visual arrangement, not source, reading, or keyboard order. Move items to change the HTML source order.

  1. Item 1: .flex-item-1 · order: 0
  2. Item 2: .flex-item-2 · order: 0
  3. Item 3: .flex-item-3 · order: 0

Your example is generated locally. This tool does not upload or save the sample text or code.

Build a Flexbox example

  1. Choose the sample size, writing direction, wrapping and alignment.
  2. Select each item to edit its text, flexible sizing, minimum behavior and visual order.
  3. Inspect the axes and preview, then copy the current CSS and HTML fragment or download the complete example.

Understand the example

The main axis follows row or column in the selected writing mode. Reverse settings change its start and end; RTL is not simply a universal horizontal flip.

Flex basis is a starting main size, not a guaranteed final width. Growth, weighted shrinking, wrapping and automatic minimum sizes all influence the browser's result.

Source-order controls change the HTML. CSS order and reverse settings change visual arrangement without changing logical reading or keyboard order.

The sample has explicit border-box dimensions, padding, borders and scrolling. Its inner available space is smaller, and system fonts or scrollbars can change layout.

Useful experiments

Give three items positive grow values and compare how extra space is shared. Change their text and automatic minima rather than assuming every flex item becomes equal.

Enable wrapping, narrow the sample and change align content. A nowrap container ignores align content; a wrapping container can use it even when only one actual line is present.

Compare LTR and RTL, then try vertical writing. Read the physical start and end labels instead of assuming row always means left to right.

Know what is generated

This is a bounded fixed-size component example, not a page builder or a responsive design guarantee. Your real content and surrounding styles require their own review.

Automatic minima can prevent the shrink result you expected. Allow below content explicitly changes both minimum dimensions; the tool does not apply that change invisibly.

Fit changes only the viewing scale. Use 100% and the contained scroll areas to inspect details; parsing support or a loaded preview does not certify every browser's rendering.

Copy HTML provides a fragment that also needs the CSS. The complete HTML download contains the same document used for preview, including its small document reset and restrictive resource policy.

Local authoring

The tool does not upload or save your sample text or generated code. Clipboard and complete-example download are explicit actions; ordinary site services retain their own privacy behavior.

Flexbox questions

Row follows the inline axis and column follows the block axis. Writing mode, RTL and reverse settings determine their physical start and end.

Basis and preferred dimensions participate in Flexbox layout rather than fixing every final size. Available space, growth, shrink factors, content minima and wrapping can change the result.

It does not apply to a nowrap single-line container. In a wrapping container its effect also depends on available cross-axis space and the lines being aligned.

No. Visual reordering does not rewrite logical source or keyboard order. Move an item in source order when you intend to change the generated HTML sequence.

Copy HTML gives the matching component fragment. The download is a complete self-contained example with the current CSS and the same document used for preview.

No. The example fixes its own settings, but system fonts, browser rendering and styles on a real site can differ. Test your actual content and environment.

No. This tool generates the example locally and only copies or downloads it when you request that action. It does not make a claim about all other site services.

Sources

These specifications describe the CSS behavior used by the example.

Reviewed 8 November 2026. The browser performs layout; these sources do not certify this implementation.

SVG to PNG

Convert a local SVG file or pasted markup into PNG, with explicit dimensions, transparency and bundled fonts.

Open tool — SVG to PNG

CSS Filter Generator

Order and repeat CSS effects, compare a specimen and copy the exact filter declaration.

Open tool — CSS Filter Generator

Fluid Font Size Calculator

Create root-relative CSS from viewport endpoints and inspect the copied size model.

Open tool — Fluid Font Size Calculator

CSS Button Generator

Style native button states, inspect keyboard focus and copy HTML and CSS.

Open tool — CSS Button Generator

CSS Border Radius Generator

Edit eight corner radii, preview a box and copy CSS in pixels or percentages.

Open tool — CSS Border Radius Generator

CSS Grid Generator

Build a bounded CSS Grid example with editable tracks, placement and named areas. Preview it, copy CSS or HTML and download the same standalone example.

Open tool — CSS Grid Generator

CSS Text Shadow Generator

Build ordered text shadows, preview plain text and copy exact CSS.

Open tool — CSS Text Shadow Generator

CSS Transform Generator

Compose repeatable 2D CSS transforms, edit px or percentage translation and origin, inspect a reference box and copy the exact current declarations.

Open tool — CSS Transform Generator

CSS Box Shadow Generator

Create ordered CSS box-shadow layers with a live preview and copyable code.

Open tool — CSS Box Shadow Generator

Image Watermark

Add a text or logo watermark to a batch of images, review each result and download individual files or a ZIP.

Open tool — Image Watermark

CSS Gradient Generator

Create linear or radial CSS gradients with editable colors, opacity and stops.

Open tool — CSS Gradient Generator

Color Converter

Convert supported sRGB HEX, RGB and HSL literals with alpha, explicit precision and current code Copy.

Open tool — Color Converter

Image to Text (OCR)

Recognize printed text in local PNG or JPEG images, choose a language and review or correct the result before copying or downloading.

Open tool — Image to Text (OCR)

QR Code Reader

Read one QR code from a local PNG or JPEG and inspect its text or content bytes without opening links.

Open tool — QR Code Reader

Color Contrast Checker

Compare foreground and background colors, adjust opacity and check WCAG numerical contrast thresholds for text and essential interface details.

Open tool — Color Contrast Checker

Print Size & Resolution Calculator

Calculate print dimensions, required pixels and effective PPI with fit or crop.

Open tool — Print Size & Resolution Calculator

Aspect Ratio Calculator

Find a width-to-height ratio or calculate a matching pixel size from one target dimension.

Open tool — Aspect Ratio Calculator

Image Compressor

Try to fit a JPEG, PNG or WebP within a target file size, with measured results and optional smaller dimensions.

Open tool — Image Compressor

HEIC to JPG

Convert supported HEIC photos locally into full-size JPG copies, with quality and background controls and verified individual or ZIP downloads.

Open tool — HEIC to JPG

Image Converter

Convert supported PNG, JPEG and WebP images locally with batch targets, transparency, background and quality controls, then review and download the encoded files.

Open tool — Image Converter

Photo Collage Maker

Arrange local photos in a grid, adjust crops and spacing, and download PNG or JPEG.

Open tool — Photo Collage Maker

Rotate & Flip Images

Rotate or mirror a local batch of static PNG, JPEG and WebP images, then review and download the processed results.

Open tool — Rotate & Flip Images

Image Cropper

Crop one local JPEG, PNG or WebP to exact pixels with visual and numeric controls. Download PNG or JPEG.

Open tool — Image Cropper

Image Resizer

Resize a JPG, PNG or WebP image by pixels or percentage, preview the result and download it.

Open tool — Image Resizer
View all tools in this category