36

Do you know of any nice looking invoice LaTeX template/class. I would like to create a web invoice engine (maybe on top of the scribtex engine) that compiles for me an invoice using the LaTeX engine (pdfLaTeX) and some data filled by a web form. Before to begin the development I'm searching for an elegant or at least nice template for invoices.

Do you have any suggestion?

2
  • 2
    I don't have a suggestion but, as a developer, I wouldn't spend the effort to get a LaTeX solution if I can achieve most of it by generating a PDF programmatically with something like iText (itextpdf.com). Of course, this is subjective. Aug 8, 2010 at 4:06
  • 1
    I'm working on exactly same stuff as you. I'm using this template (with a lot of editing, of course) Latex invoice template
    – Rishi Dua
    Dec 25, 2013 at 6:30

5 Answers 5

9

Take a look at the scrlttr2 package. One of the most versatile letter classes. I made an invoice template based on it and it looked great. Sorry I can't post the source here at the moment (needs editing and my machine can't compile it) but I will briefly comment what I did.

I configured scrlttr2 to get a nice looking business-like letter (KOMA-Script has > 160 pages on scrlttr2). The invoice is embedded in the body of the letter by using the invoice package.

3
  • It would be great if you could post this when it's in shape. I could use an invoice template as well. (Or even post it when it's not in shape!)
    – rogerl
    Aug 8, 2010 at 13:03
  • @rogerl: I briefly commented what I did. In fact much of the material in the template is about setting up the business letter which has many private details.
    – Leo Liu
    Aug 8, 2010 at 13:46
  • I don't understand your previous comment. Did you share the template now, or did you decide not to?
    – arnuschky
    Jan 4, 2016 at 12:06
23

Dapper InvoiceA billable-time invoice featuring style over substance

It's light on functionality, but it looks a fair bit more modern than any other LaTeX template I've seen published out there (which is why I took the time to write it). I'm not much of a LaTeX author (the community here helped me a bunch) and I'm not a designer (it borrows heavily from moderncv), but maybe it'll be of use to someone as there's so little out there in LaTeX when you're looking for a billable-time invoice.

Here's an example screenshot:

example screenshot

1
  • Very nice! And still holding up to this day in 2021. I added a PR to include a Docker version of usage of this. Combined with gcinvoice to export GNUCash invoices, and some python to replace python vars, this is a very powerful setup.
    – eduncan911
    Jul 24, 2021 at 3:12
22

This is an old question, but here is a minimal that can display a fairly easy to understand invoice table. Add your logo and tax, if required.

The code automatically auto-increments the item counter and calculates totals.

enter image description here

It uses the fp package for calculations to ensure accuracy. It uses a longtable, as some invoices are rather long.

Here is the MWE. Embellish it with your logo and other details to customize it.

\usepackage{fp}
\usepackage{booktabs}
\usepackage{ragged2e}
\usepackage{longtable}
\newcounter{cnt}
\setcounter{cnt}{0}
\def\inc{\stepcounter{cnt}\thecnt}
\gdef\TotalHT{0}
\newcommand{\product}[3]{%
\inc &#1  &#2   &#3  &\FPmul\temp{#2}{#3}\FPround\temp{\temp}{2}\temp 
%% Totalize
\FPadd\total{\TotalHT}{\temp}%
\FPround\total{\total}{2}%
\global\let\TotalHT\total%
\\ }
\newcommand{\totalttc}{
   \TotalHT  }
\begin{document}
\RaggedRight
\begin{longtable}{cp{4.2cm}rrr}
\toprule
Item   &Description & Price & Qty & Total\\
\midrule
    \product{Computer peripherals}{1000.00}{1}
    \product{Harddisk 2000E}{2000}{1}
    \product{The \TeX book}{100.00}{100}
    \product{Product Four}{5000.00}{1}
    \product{Product Five}{5000.00}{2}
\midrule
    &&&& Total \totalttc\\
\bottomrule
\end{longtable}
\end{document}
2
  • How to add a Discount column before a Total column?
    – Edy Jo
    Jan 11, 2015 at 0:56
  • How can I replace . decimal separator with , ? Thank you Oct 16, 2017 at 16:11
6

Although this isn't really a LaTeX template per se, I stumbled upon https://github.com/mrzool/invoice-boilerplate and found it very useful.

It's basically a tool for automating the invoice-creation. You fill in the details in a YAML file and then it runs pandoc (which in turn invokes XeLaTeX) to create the PDF. Very handy :)

3

I use Context for this, and use Context's layers to set out text on the PDF of my letterhead. This works well.

It was, in fact, generating letters and invoices that led to me switching from Latex to Context. If I were to try and do this using Latex, it looks like using Tikz would be the way to go, but the learning curve for doing this kind of thing with Tikz looks higher than that of Context, especially if you know any Metapost already.

1
  • 1
    Thanks for these thoughts Charles. Can you share some estimate of the learning curve on Metapost and Context? Asking as someone who knows enough LaTeX to write a vanilla \documentclass{article} but little else (no plain TeX for instance; anything with \..@.. scares me). Jul 2, 2014 at 20:59

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.