I've had occasion to typeset extraordinarily large matrices, which I didn't seriously expect anyone to expect in detail (without a computer) or print, but I needed it to be obvious that they were completely explicit and written down somewhere.

By trial and error, I found a really large paper size that would compile (about 5.5m) in pdflatex and fit my matrices on a reasonable number of sheets. (I used the geometry package to choose custom page sizes.) But it would have been easier if I'd been able to find out:

What are the limitations on paper sizes in pdflatex?

2 Answers 2


From the immensely useful TeX by Topic:

\maxdimen 16383.99999pt; the largest legal dimension.


Internally TEX works with multiples of a smallest dimension: the scaled point. Dimensions larger (in absolute value) than 2^30 − 1sp, which is about 5.75 metres or 18.9 feet, are illegal.

Knuth delivered a beautiful extended dig at "modern" software development practices at the 2010 TUG meeting, during the early part of which he referred to the value of \maxdimen. I can't work out if he was serious when he suggested it had been a mistake to fix the largest dimension in TeX at this rather small value.

Perhaps it is worth mentioning that as far as I know, pdflatex does not apply any more restrictive limits than TeX itself for this application. So the limitation that is relevant here is the internal TeX one.

  • 4
    I'll keep that in mind if I ever want to typeset a billboard using TeX.
    – PersonX
    Jul 28, 2010 at 15:19
  • 5
    Of course, typesetting a billboard could be done by upscaling a smaller document. It's not like one needs 72.27sp per inch resolution... Jul 28, 2010 at 16:51
  • 2
    Personally, I'm always peeved that TeX can't deal with dimensions on the order of 1 farshimmelt potrzebie.
    – Sharpie
    May 10, 2011 at 2:32

Since you mention pdfTeX, I assume that you want to produce PDFs. The PDF norm mentions this "architectural limit":

The minimum page size should be 3 by 3 units in default user space; the maximum should be 14,400 by 14,400 units. In versions of PDF earlier than 1.6, the size of the default user space unit was fixed at 1⁄72 inch, yielding a minimum of approximately 0.04 by 0.04 inch and a maximum of 200 by 200 inches. Beginning with PDF 1.6, the size of the unit may be set on a page-by-page basis; the default remains at 1/ 72 inch.

200 inches are 508 cm. While this limit is probably not enforced by any PDF-producing program in the TeX world, I'd advise against exceeding it.

  • 5
    These 14,400 units are in user space. But the default user space unit of 1/72 inch (the minimum) can be changed to a maximum of 75,000 (that is since PDF-1.6, I believe). That gives you a maximum of 381 kilometers in (virtual) page dimensions! May 8, 2015 at 4:03

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.