PureDevTools

CSS Grid Generator

Build CSS grid layouts visually and generate clean code

All processing happens in your browser. No data is sent to any server.

Column Definitions

1
2
3

Grid Preview

Click a cell to set a span starting from it.

Generated CSS

.grid-container {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-template-rows: 1fr 1fr 1fr;
  gap: 8px;
}

Why This Tool

CSS Grid is the most powerful layout system in CSS, but building complex grid templates from scratch requires mental arithmetic. This visual builder lets you define rows, columns, gaps, and areas by interacting with a visual grid, then generates the CSS code for you.

How It Works

Set the number of rows and columns, define their sizes (px, fr, auto, minmax), and adjust the gap. Click and drag to define named grid areas. The tool generates clean CSS grid code including grid-template-columns, grid-template-rows, and grid-template-areas. Copy the code into your project.

Related Tools

More CSS Tools