# Export Excel tables to Overleaf

Good morning everyone,

I have been trying to export Excel tables to my Overleaf file. I have succeeded to some extent using \includegraphics command, but the problem with that is that the font size is not editable on Overleaf. The attached is done using the command.

I have also tried to convert Excel to a .tex file using an add-in excel2latex but it did not work very well on Overleaf.

• Why do you cover the table by black rectangle? If you don't want to show us the information, you can type in each cell A, B, C, or something like that.
– user156344
Nov 5 '18 at 15:53
• Nov 5 '18 at 16:09
• When I want to retain the exact formatting, I usually save the sheet as pdf and then include as graphics in latex. Nov 6 '18 at 6:23

One possible solution I can think of from the top of my head is to load the excel table with the python module pandas and than use the export as tex file function in pandas.

#As example:
import pandas as pd
df.to_latex(output.tex)

• Thank you for suggesting a solution. Unfortunately, I have not used Python before. Nov 5 '18 at 15:48
• Thank you! The only fix is that pandas does not interpret xlsx, only xls. But it is a great solution! May 1 at 22:28

Have you tried saving the excel file as a CSV and importing it to:

https://www.tablesgenerator.com/

You will have to do the formatting again but you can get it exactly how you want it and fairly quickly

• I've used this before, but this site seems to be broken now: it dumps all the table's data into just the first column. Feb 10 '19 at 4:17
• works for me real good. Oct 24 '19 at 12:11

Generate your data as a CSV file. Use the datatool package to load and display the data.

\document{article}
\usepackage{datatool}