Can You Use a Page-Breaking Longtable in Multicolumn?
At a glance
- 1. End the columns
Close the multicols environment before starting the longtable.
- 2. Place the table
Use longtable in normal one-column page layout, where it can control page breaks.
- 3. Resume columns
Start a new multicols environment after the table if you need more two-column text.
A longtable can split a table across pages and repeat its heading, but it cannot do that inside the multicols environment. The multicol package manages columns as part of page layout, while longtable needs to manage page output itself. They cannot both control the same stretch of document.
The usual fix is to end multicols, put the longtable in the document’s normal one-column layout, and start a new multicols environment afterward if you still need columns.
Put the longtable outside multicols
Here is a minimal example. The table is deliberately placed between two separate multicols environments:
\documentclass{article}
\usepackage{multicol}
\usepackage{longtable}
\usepackage{booktabs}
\begin{document}
\begin{multicols}{2}
Text in two columns goes here. Add enough text to fill the columns as needed.
\end{multicols}
\begin{longtable}{@{}llr@{}}
\caption{Example measurements}\label{tab:measurements} \\
\toprule
Item & Description & Value \\
\midrule
\endfirsthead
\multicolumn{3}{c}{\tablename\ \thetable{} -- continued} \\
\toprule
Item & Description & Value \\
\midrule
\endhead
\bottomrule
\endfoot
A & First measurement & 12 \\
B & Second measurement & 18 \\
C & Third measurement & 25 \\
D & Fourth measurement & 31 \\
% Add enough rows for the table to continue onto another page.
\end{longtable}
\begin{multicols}{2}
Text in two columns resumes here.
\end{multicols}
\end{document}
This example needs the multicol, longtable, and booktabs packages. The \endfirsthead section defines the heading for the first page; \endhead marks the heading that is repeated on later pages. The \endfoot section defines the footer for continued pages. Add enough rows to exceed the available page height to see the table break and the repeated heading.
A longtable is not a float, so it appears where it is written rather than moving to a preferred location. If you want it to begin on a fresh page, put \clearpage immediately before it. That also outputs any pending floats before starting the table.
If the table must remain in a column
Use a normal tabular environment if the table is short enough to fit in one column. Make its columns fit the available column width; for example, use paragraph columns such as p{...} for wrapped text. A tabular does not split across pages, so it must fit as a whole in the space available.
If the table is too long for one column, there is no automatic combination that makes longtable break from one multicols column to the next. You can instead divide the content into separate tables and place each where it belongs, or move the complete table to one-column layout as above. Splitting manually means you must manage headings, captions, and numbering yourself.
Common mistakes
- Putting
longtableinside amulticolsenvironment: Moving it inside atablefloat does not solve the conflict.longtableis not intended to be nested in a float or in a boxed layout. - Expecting a
tabularto continue on another page: It cannot break across pages. Uselongtableoutside the columns, or split the table manually. - Using
\onecolumnand\twocolumnfor amulticolssection: Those commands switch the document’s column mode and are not the right way to end amulticolsenvironment. Closemulticolswith\end{multicols}and reopen it with\begin{multicols}{2}. - Assuming a short test table proves page breaking works: A table breaks only when it is taller than the remaining page space. Add enough rows to test the continuation heading and page split.
If you need one table that spans the full text width and continues over pages, place it outside multicols. If it must be confined to a single column, use a non-breaking table and keep it short enough to fit.
References
Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.