Generator

LaTeX table generator, for a clean tabular.

Set rows, columns, and per-column alignment, paste cells from a spreadsheet, and copy a tabular environment. Booktabs rules or plain hlines, with an optional caption. Live preview, no signup, no upload.

  • No signup
  • No upload
  • Booktabs or hline
  • Live preview

Writing the rest of the document in markdown? Markdown to LaTeX →

Need a GitHub-flavored table instead? Markdown table generator → or start from a file with CSV to markdown table →.

Live generator·
latex217 chars
% Requires \usepackage{booktabs} in the preamble.
\begin{tabular}{lll}
\toprule
Header 1 & Header 2 & Header 3 \\
\midrule
Cell 1-1 & Cell 1-2 & Cell 1-3 \\
Cell 2-1 & Cell 2-2 & Cell 2-3 \\
\bottomrule
\end{tabular}
preview
Header 1Header 2Header 3
Cell 1-1Cell 1-2Cell 1-3
Cell 2-1Cell 2-2Cell 2-3

Booktabs rules need \usepackage{booktabs} in the preamble. Wrap the fragment in a document — \documentclass{article}, then \begin{document} — before compiling.

Why this generator

A grid in, a tabular out.

Hand-writing a tabular means counting alignment letters, escaping every ampersand, and remembering whether the rule is a hline or a booktabs command. This generator keeps the grid editable and emits source you can drop into a paper.

  • Local-first generation

    Cells, alignment, and the emitted LaTeX stay in your browser. Nothing is uploaded, logged, or analyzed.

  • Per-column alignment

    Each column is l, c, or r. Default and left both emit l, which is what LaTeX uses when you do not specify otherwise.

  • Booktabs or hline

    Booktabs gives toprule, midrule, and bottomrule with no vertical lines. Turn it off for a classic grid of hlines.

  • Paste a spreadsheet

    Cells copied from Excel or Google Sheets arrive as tabs. CSV works too. The first row becomes the header.

Preamble

What to load before you compile.

The download is the table, not a full document. With booktabs rules on, add \usepackage{booktabs} to the preamble. With hline rules, tabular and \hline are already in the LaTeX kernel. A table float, caption, and label come with the standard classes — article, report, and book. Wrap the fragment in \documentclass{article} and \begin{document} before running pdflatex.

How it works

Three steps, no friction.

  1. 01

    Fill the grid

    Type into the cells, or paste CSV, TSV, or a block copied from Excel. Up to 12 columns and 24 body rows.

  2. 02

    Align and choose rules

    Pick left, center, right, or default for each column. Toggle booktabs rules, and add a caption if you want a table float.

  3. 03

    Copy or download

    Copy the LaTeX source, or download a .tex file. The preview shows the same alignment and rules.

FAQ

Common questions

Why does my table overflow the page?
Columns set to l, c, or r never wrap, so a wide row runs past the margin. tabular also will not break across pages, so a long table overflows the bottom. For width, edit a column to p{3cm} (or use tabularx) so the text wraps, or scale the whole tabular with \resizebox from graphicx. For length, switch the environment to longtable, which splits rows across pages. This generator keeps the column spec to l, c, and r so the fragment stays predictable.
How do I merge cells?
This generator writes one cell per column. It does not emit \multicolumn or \multirow. To span columns, replace those cells in your editor with \multicolumn{2}{c}{heading}. Vertical spans need \usepackage{multirow} and a \multirow command, which you add by hand after copying the tabular. If the rest of the document is markdown, the Markdown to LaTeX converter can turn the surrounding prose into a matching fragment.
Which packages does the output need?
With booktabs rules, add \usepackage{booktabs}. With hline rules, tabular and \hline come from the LaTeX kernel and no extra package is required. A table float, caption, and label are part of the standard classes (article, report, book). The download is a fragment: wrap it in \documentclass{article} and \begin{document} before you compile.
Will characters like &, %, and _ break the table?
No. The generator escapes & % $ # _ { } ~ ^ and \ in every cell and in the caption, so a percent sign becomes \% and an ampersand becomes \&. Newlines inside a cell are collapsed to spaces, because a raw line break would end the row early.
Can I paste from Excel or a CSV?
Yes. Paste tab-separated cells copied from Excel or Google Sheets, or comma-separated text, into the paste box and fill the grid. The first row becomes the header. If you want a GitHub-flavored markdown table from the same CSV instead, use CSV to markdown table.

Writing more than a table? Use the editor.

Markdown Writer is a local-first editor with synced scrolling, an outline, PDF export, and math.

Open the editor