LaTeX Table Generator
Turn CSV or spreadsheet cells into LaTeX tabular, tabularx or longtable code with booktabs rules, caption, label and escaped special characters.
Typing a LaTeX table by hand means counting ampersands, ending every row with \\ and escaping every % or _ that would otherwise break the build. Paste CSV or cells copied from Excel or Google Sheets and get ready-to-compile tabular, tabularx or longtable code with professional booktabs rules, a caption and a label for \ref. Special characters are escaped correctly, so a cell like 50% & $5 prints exactly as written.
How to use this tool
- Paste your data, with the header in the first row.
- Choose tabular, tabularx (fills the text width) or longtable (breaks across pages).
- Pick booktabs rules, simple \hline lines or a full grid.
- Optionally set the column alignment, caption and label.
- Copy the code and add the packages listed under it to your preamble.
Formula
cell & cell & cell \\ · \begin{tabular}{lrr} … \end{tabular}
The column spec has one letter per column: l, c or r align left, centre or right; p{4cm} wraps text in a fixed width; X (tabularx only) shares the free width. By default numeric columns are right-aligned and text left-aligned. The ten special characters are escaped as \& \% \$ \# \_ \{ \} and \textasciitilde{} \textasciicircum{} \textbackslash{}.
Example
The sample fruit list (3 columns, 3 rows) becomes a table float with \centering, \caption{Fruit prices} and \label{tab:fruit} around \begin{tabular}{lrr}: Fruit is text so it gets l, Qty and Price are numbers so they get r. \toprule, \midrule and \bottomrule frame the bold header and the rows Apple & 3 & 1.20 \\ and so on. Add \usepackage{booktabs} to the preamble.
Frequently asked questions
Why booktabs?
Its rules have proper spacing and weights and it avoids vertical lines, which is the style most journals and style guides recommend. Choose the grid option if you need vertical lines.
My table is wider than the page. What now?
Use tabularx so text columns wrap within \linewidth, or give long columns p{width}. For many rows use longtable, which repeats the header on every page.
Why did my text with \textbf{} turn into \textbackslash{}?
Escaping treats every backslash as text. Untick "Escape LaTeX special characters" if your cells already contain LaTeX commands or math.
Where does the caption go?
Above the table, as most style guides ask for tables. The label comes after the caption so \ref gets the right number.
Sources
Last updated:
Page address with these inputs: https://kakao.mobile/tools/latex-table-generator/
Cite or embed this tool
kakaoCalc. (2026, November 8). LaTeX Table Generator. https://kakao.mobile/tools/latex-table-generator/
“LaTeX Table Generator.” kakaoCalc, 8 Nov. 2026, kakao.mobile/tools/latex-table-generator/.
Paste this code into your page. The widget runs in your visitors' browsers, shows no ads and keeps a link back to this page. Embedding terms