I need to create just a specified number of sentences of dummy text (rather than a long paragraph). Can I use lipsum to do this? If not, then what can I use? The idea is to be able to create a MWE that doesn't contain a lot of distracting text in the source code, but allows me to use smaller numbers of sentences than I can get with \lipsum[n].

  • 2
    Then what? What do you mean? If you need a more specific amount than lipsum or blindtext or kantlipsum provide, you can just write arbitrary text or copy the relevant amount of text from those packages.
    – cfr
    Commented Jul 11, 2015 at 20:26
  • 3
    you can use your \mylipsum command: \newcommand{\mylipsum}{just dummy text}
    – touhami
    Commented Jul 11, 2015 at 20:36

5 Answers 5


One can defines command \mylipsum

\newcommand{\mylipsum}{just dummy text}



\newcommand{\mylipsum}{just dummy text}
\newcommand{\Mylipsum}{\mylipsum{} \mylipsum}



With some help from xparse we can extract a rich supply of sentences from lipsum; precisely 1498, I guess they're sufficient.


% store a big set of sentences
\unpacklipsum[1-100] % it was \UnpackLipsum before version 2.0

% unpack \lipsumexp
\seq_new:N \g_lipsum_sentences_seq
\cs_generate_variant:Nn \seq_set_split:Nnn { NnV }
\seq_gset_split:NnV \g_lipsum_sentences_seq {.~} \lipsumexp

  \lipsumsentenceaux #1
  \IfNoValueTF { #2 }
    \seq_item:Nn \g_lipsum_sentences_seq { #1 }.~
    \int_step_inline:nnnn { #1 } { 1 } { #2 }
      \seq_item:Nn \g_lipsum_sentences_seq { ##1 }.~


\section{Seven sentences}


\section{Three sentences}


\section{Some single sentences}







enter image description here

  • The code no longer compiles because \UnpackLipsum has been deprecated.
    – Troy
    Commented Nov 29, 2018 at 21:25
Hello world.

writes Hello world 10 times.


Starting from version 2.0 on, the lipsum package provides a second optional parameter to the \lipsum command which selects a range of single sentences from the paragraphs selected by the first optional parameter. The syntax is

\lipsum[<paragraph range>][<sentence range>]

where each <range> can be a single number n or a range n-m.




enter image description here

  • 2
    How to make sure I have lipsum 2.0? The previous examples don't work for me, so I suspect I have the old version of lipsum Commented Feb 13, 2020 at 13:28
  • When I use this \lipsum[1][1] I get Illegal Unit of Measure (pt inserted). Commented Mar 17, 2021 at 10:38
  • This is the correct answer.
    – bela83
    Commented May 9, 2022 at 10:21

You can use a macro for the dummy text and a loop to repeat it, taking as an argument the number of repetitions. These commands work in any variety of TeX, but I illustrate their use in a LaTeX document.


% Define the dummy sentence, an ancient palindrome.
\def\sator{Sator Arepo tenet opera rotas.}

% Create a command to print the sentence repeatedly.
% Argument #1 is the number of times to repeat it.
    \loopcounter = #1
        \sator\ %
        \advance\loopcounter by -1
        \ifnum\loopcounter > 0




\item \sator
\item \dummysentences{3}
\item \dummysentences{2}


enter image description here

See also my answer here: Is there a dummy package like Lipsum or Blindtext for Tables and Figures?

  • ... and of course: \def\sator{\noindent\ttfamily sator\\ arepo\\ tenet\\ opera\\ rotas}.
    – jon
    Commented Jul 11, 2015 at 21:49
  • @jon See the command \satorfig from the package in the answer I link to. :) Commented Jul 11, 2015 at 22:06

You must log in to answer this question.

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