185

How can I make text that is larger than the size of the output of {\Huge ...}?

I would like to be able to make text arbitrarily large (even if that is done by some suboptimal scaling routine).

10 Answers 10

137

You can use the Memoir document class. It provides two things that are relevant to your question:

More Base Font Sizes


The standard LaTeX document classes only allow you to choose 10pt, 11pt or 12point as the "base" font size for your document. Memoir provides many more choices: 9pt, 10pt, 11pt, 12pt, 14pt, 17pt, 20pt, 25pt, 30pt, 36pt, 48pt and 60pt. Since all font size declarations are affected by the base font size, using a bigger base font size will make \Huge render in a bigger font.

The \HUGE Font Size


For when it absolutely has to be bigger than \Huge, crank it to 11 with \HUGE.

alt text

6
  • 17
    The answer was great, and the xkcd made it even better!
    – Vivi
    Jul 29, 2010 at 12:03
  • 11
    Using memoir is a total hack. But it makes sense that someone writing his memoirs would need a larger font ...
    – g33kz0r
    Apr 17, 2013 at 18:11
  • 6
    Is this an answer? Given a base font size, how do you obtain text larger than \Huge? Still unanswered... Nov 9, 2017 at 16:16
  • 1
    The following sets global font size to 36pt: \documentclass[36pt,extrafontsizes]{memoir}
    – ebrahim
    Oct 5, 2018 at 13:24
  • 2
    +1, but just as a nitpick, switching to a new document class is usually overkill and may also bring new changes and headaches. Further, if you're not writing a paper/book/... to begin with, but using (say) beamer instead, it'll be outright impossible.
    – chsk
    Jan 8, 2022 at 10:06
95

If you use Type 1 fonts (e.g., package mathptmx or mathpazo), you can simply use the \fontsize command with large point sizes:

{\fontsize{50}{60}\selectfont Foo!}

(The first parameter (50) is font size. The second parameter (60) is line spacing. An appropriate line spacing depends on the font. Something like 1.2 times font size is commonly used with CM fonts. But it does not really matter if you are typesetting just one line of text.)

8
  • 7
    Could you add an explanation what the meaning of the first and 2nd argument is (50 and 60)? Width times height in points? Oct 18, 2011 at 9:47
  • 1
    @JukkaSuomela: Is 50 the biggest font size? I'm trying to get the header as big as possible (source). Terve! Oct 3, 2012 at 23:29
  • 1
    How / Where to check if the fonts I'm using are indeed Type 1 (or not) ? Jul 9, 2013 at 15:44
  • 1
    You can use this with any type of font, not just type1, you may need to modify the fd files (eg fix-cm package in the case of cm fonts) Dec 17, 2013 at 19:15
  • 3
    Tried to play with line spacing parameter but did not see it having any effect.
    – ajeh
    Jul 28, 2016 at 16:50
56

A quick search on CTAN turned up anyfontsize. To quote the description:

The package allows the to user select any font size (via e.g. \fontsize{...}{...}\selectfont), even those sizes that are not listed in the .fd file. If such a size is requested, LaTeX will search for and select the nearest listed size; anyfontsize will then scale the font to the size actually requested.

Similar functionality is available for the CM family (type1cm), for the EC family (type1ec), or for either computer modern encoding (fix-cm); the present package generalises the facility.

51

The \resizebox command (from graphicx package) is convenient if you want to produce, e.g., a title that fills the entire page width:

\resizebox{\linewidth}{!}{\itshape Foo!}
3
  • 3
    That's a neat solution...
    – Seamus
    Aug 12, 2011 at 9:58
  • 3
    Keep in mind, that linebreaks require a workaround
    – Jakob
    Jul 29, 2013 at 14:56
  • 1
    This is much easier and to the point for what I'm trying to do as well :)
    – pefmath
    Oct 1, 2015 at 18:27
23

To extend on @Yiannis and the comment by @isomorphismes I also needed to have the fix-cm package loaded

\documentclass[10pt,a4paper]{article}    

\usepackage{fix-cm}    

\makeatletter
\newcommand\HUGE{\@setfontsize\Huge{50}{60}}
\makeatother    


\begin{document}

\Huge Huge text

\HUGE HUGE text

\end{document}
2
  • 2
    This was the only fix that worked for me!
    – Blairg23
    May 16, 2017 at 3:02
  • The fix-cm docs state that the package should be loaded with \RequirePackage{fix-cm} before \documentclass.
    – chsk
    Jan 8, 2022 at 9:43
21

In your class add:

%% Define a HUGE 
\newcommand\HUGE{\@setfontsize\Huge{38}{47}} 
1
  • 11
    In order to make this work, I needed to preface it with \makeatletter and postface it with \makeatother. May 26, 2015 at 5:16
17

In XeTeX (using fontspec) you can use system fonts many of which have a "Scale" attribute you can set to a large number. For instance, in one document I have this line for a largeish Japanese font:

\newfontinstance\bigkanafont[Color=000000,Scale=2.5]{Hiragino Mincho Pro W3}
8

According to http://www.mostlymaths.net/2009/03/big-fonts-in-latex.html, you can use the fix-cm package to get arbitrary-size fonts. In fact, searching CTAN for fix-cm seems to give a few different packages that provide this functionality. I've never used any of them myself so I couldn't tell you which ones might work or not, but it shouldn't be hard to try them.

1
  • Yeah, searching CTAN for fix-cm gives three results: type1cm, which recommends fix-cm, fix-cm itself, and the more general anyfontsize that's in Andrew Stacey's answer. Jul 31, 2010 at 1:56
4
\scalebox{2}{\fontsize{32pt}{0pt}\selectfont \textbf{Your text}}

This piece of code worked for me and also provided better control over the size by adjusting the scale factor

2
  • 2
    Better use a scalable font than scaling up.
    – Johannes_B
    Jul 31, 2016 at 11:07
  • 1
    A solution that actually works...
    – luchonacho
    May 2, 2022 at 16:13
3

There is also a package called moresize that can be useful.

And another trick is to use, 10pt, 11pt, or 12pt but with a proportional, smaller "geometry" than the one desired.

3
  • 3
    Whilst this may theoretically answer the question, it would be preferable to include the essential parts of the answer here, and provide the link for reference.
    – bodo
    Feb 25, 2014 at 9:30
  • 4
    Thanks for mentioning my ancient moresize package. It does not provide arbitrary fontsizes however, just some more, so that one could try the EC font design sizes for example, and it can tune math scriptsize settings that should bring multiline headlines with math in a better shape. To solve the OP's problem, I'd go with one of the other recommendations.
    – ccorn
    Jul 31, 2016 at 11:29
  • 2
    @ccorn Anyway, moresize is perfect for adding \HUGE without changing document class. ;) Jan 22, 2023 at 2:50

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .