Build tables in a visual grid, configure alignment and rules, then copy the LaTeX code. No LaTeX knowledge required.
\begin{tabular}{ccc}
A & B & C \\
1 & 2 & 3 \\
\end{tabular}
LaTeX tables are built using the tabular environment. The basic syntax is \begin{tabular}{alignment}\n ... \n\end{tabular}.
Columns are separated by &, rows end with \\, and alignment is specified using letters: l (left), c (center), r (right).
Optionally, wrap the tabular in a table float environment to add a caption and label, making your table referenceable in your document.
| Spec | Description | Example |
|---|---|---|
| l | Left-aligned column | \begin{tabular}{l} |
| c | Centered column (default) | \begin{tabular}{c} |
| r | Right-aligned column | \begin{tabular}{r} |
| p{3cm} | Paragraph column (fixed width, top-aligned) | \begin{tabular}{p{3cm}} |
| | | Vertical rule between columns | \begin{tabular}{|c|c|} |
| @{} | Remove spacing between columns | \begin{tabular}{l@{}r} |
The booktabs package provides professional-quality horizontal rules designed specifically for tables. It replaces \hline with three commands: \toprule, \midrule, and \bottomrule. The booktabs documentation explicitly recommends not using vertical rules, as they clutter tables and reduce readability. Use booktabs for publication-quality tables; use \hline for quick reference tables.
\begin{tabular}{lcc}
\toprule
Name & Score & Grade \\
\midrule
Alice & 95 & A \\
Bob & 87 & B \\
\bottomrule
\end{tabular}
\begin{tabular}{lcc}
\hline
Name & Score & Grade \\
\hline
Alice & 95 & A \\
Bob & 87 & B \\
\hline
\end{tabular}
LaTeX reserves certain characters for commands and structure. To use them literally in text, prefix with a backslash or use a special command. The table below shows how to escape each special character in LaTeX table cells.
| Character | Escape Sequence | Used For |
|---|---|---|
| & | \& |
Column separator in tables |
| % | \% |
Comments |
| $ | \$ |
Math mode delimiter |
| # | \# |
Macro parameter |
| _ | \_ |
Subscript in math mode |
| { | \{ |
Group delimiter |
| } | \} |
Group delimiter |
| ~ | \textasciitilde{} |
Non-breaking space |
| ^ | \textasciicircum{} |
Superscript in math mode |
| \ | \textbackslash{} |
Escape character |
When the "Cells contain LaTeX code — do not escape" option is checked, raw characters are passed through as-is, allowing you to type math expressions like $\alpha$ without escaping the dollar signs.
The tabular environment creates the actual table. The table environment is a floating container that wraps tabular, allowing you to add a caption, assign a label for cross-referencing, and have LaTeX place the table in the best location on the page. Use table for formal documents; use tabular alone for inline or quick tables.
Use vertical rules in the column specification: {|l|c|r|} creates a border on the left and right edges, and between each column. Horizontal rules are added with \hline (standard) or \toprule, \midrule, \bottomrule (booktabs). Combine them for a fully boxed table.
The booktabs package philosophy emphasizes readability. Vertical rules are seen as visual clutter that makes tables harder to read. The package provides beautiful horizontal rules instead. If you need a fully bordered table, consider using a different style or sticking with standard \hline.
Yes! Copy your data (including the header row) and paste it into the "Paste CSV/TSV" area. The tool auto-detects commas or tabs as separators. It handles quoted fields in CSV, so complex data with embedded separators is supported.
Unicode characters are allowed, but LaTeX needs explicit support. Add \usepackage[utf8]{inputenc} to your preamble if using pdfLaTeX. Better yet, use XeLaTeX or LuaLaTeX, which handle Unicode natively. The generator will warn you if Unicode is detected.
Use the p{width} column specifier to set fixed widths, or adjust text size with \small or \tiny before the tabular environment. For very wide tables, consider \begin{table}[h]\small\begin{tabular}... or rotate the table with the rotating package.