I'm having serious problems understanding the syntax of LaTeX well. I know a lot of programming languages but LaTeX still is a little cryptic for me. Do you know what the key to fully understanding it is?

  • 3
    Are you talking about using LaTeX for document preparation (e.g. for writing articles), or are you talking about programming in LaTeX (e.g. for creating new style files or class files, for other people to use to write documents such as articles)? Jan 6, 2011 at 9:03
  • 3
    i'm talking about "Understand" LaTeX, not only limit to the use.It is not difficult create a general document using copy-paste and edit little stuff, but when i face a trouble or something that i want to achieve that is not so trivial i start jumping from forum to forum, website to website, hoping that someone else has this magic answer. I feel unable to machinate by my self a solution, that is a very disappointing feeling
    – mjsr
    Jan 6, 2011 at 17:44
  • Related question (if not identical): package writing - Where do I start LaTeX programming? - TeX - LaTeX Stack Exchange
    – user202729
    Apr 3, 2022 at 18:22

5 Answers 5


Since LaTeX builts on TeX, a very good foundation to understand its syntax is learning the TeX syntax. Here are helpful documents (I took it from a list on my blog):

Specifically for LaTeX syntax, there's a huge amount of documentation and there are many books and online tutorials and introductions. For understanding what the LaTeX author Leslie Lamport meant with LaTeX syntax extensions, I recommend to read his book "LaTeX: A Document Preparation System".

  • great, excellent free references, i'm going to start reading them right away, i'm tired of not understand well this language.
    – mjsr
    Jan 8, 2011 at 2:02
  • Trying the first link TeXbook: How can I read this on my phone? What link do I need to click? fot, log, dvi, typ?
    – jjk
    Dec 12, 2022 at 15:41
  • From that CTAN page: "it should not be processed without Knuth’s direct permission". That's why there is no PDF or DVI file, the license doesn't allow it. It is for reading the source: the .tex file and the others. You can use any text editor or viewer. The TeXbook is available in printed format, also in cheaper student editions.
    – Stefan Kottwitz
    Dec 13, 2022 at 7:26

The key to understanding the syntax or rather shall I say to get used to it, is to do a bit of reading and programming in TeX. The best source of information on TeX is the Knuth's TeXbook. Trying to understand LaTeX reading its source alone is like trying to understand a computer language by reading its standard library.

The language is a bit cryptic but so is any language that one does not understand well (try Erlang or Brainfuck or even some of the code for Perl)! Perseverance is a good attribute to have when dealing with TeX/LaTeX!

  • 5
    Did you just motivate your statement that any new language is cryptic with Brainfuck?
    – Ben
    Jan 8, 2011 at 0:48
  • 2
    @Ben: +1, Brainfuck is a really extraordinary motivation. Jan 8, 2011 at 10:02
  • 2
    Wow, I wasn't actually expecting anything to turn up when I entered "brainfuck" in Wikipedia search -- I now know better and all the sudden LaTeX seems ridiculously easy :)
    – doncherry
    May 18, 2011 at 0:43

I suggest you to read The Not So Short Introduction to LATEX 2ε several pages a day and do many real experiments.

Theoritically you need only 157 minutes in total to read the tutorial. And if you still have problems, just post it in a new thread.


The Wikibooks entry on LaTeX has an awesome amount of basic tutorials, examples, explanations, etc. It's pretty thorough for a beginner and yet has a very well-laid-out structure that can easily accommodate people of any level of experience.


If you are talking about doing document preperation with LaTeX, then it may help to remember that LaTeX works more like a markup language than a programming language. Try thinking more in terms of HTML (and CSS) than C/Python/VB.

  • Try thinking more in terms of HTML (and CSS) than C/Python/VB. so you suggest him to learn Latex by learning another markup language?!
    – CroCo
    Nov 14, 2021 at 9:04

You must log in to answer this question.

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