Skip to content

Free tool

LaTeX Error Explainer

Paste a LaTeX log or a single error message. The tool finds the first real error, names the line, explains the cause in plain words and says how to fix it. It also groups the warnings: undefined citations and references, overfull boxes, missing characters. No account needed.

The whole .log file gives the best result, but a single error message works too. The log stays in your browser.

2. Read what went wrong

Paste a log on the left, or press Example to see how it works.

Compile it

Test the fix without installing anything

LaTeX Cloud Studio opens a starter article in the browser with a full TeX Live. Paste the part of your document that fails into main.tex and compile it there.

How to read a LaTeX error

An error in the log has three parts. A line that starts with ! states the problem, for example ! Undefined control sequence. A line that starts with l. and a number gives the source line and the text LaTeX had read. The rest of that source line follows, indented, on the next line of the log. The break between the two shows exactly where LaTeX stopped.

The tool reads these parts for every error, recognises more than thirty common messages and puts the first real error on top. Messages such as Emergency stop only say that the run ended; the cause is the error before them.

The errors people meet most

  • Undefined control sequence: a command is misspelled or its package is not loaded. The tool names the package for common commands, such as graphicx for \includegraphics.
  • Missing $ inserted: an underscore, a ^ or a maths command in normal text.
  • File not found: a package name, an image path or an \input path does not match a file.
  • Runaway argument: a closing brace is missing.
  • Misplaced alignment tab character &: an ampersand in text must be written \&.

Guides for each kind of problem

Questions

Where do I find the LaTeX log?

LaTeX writes a file with the name of your main file and the ending .log, for example main.log, into the same folder. Editors show it in a log or output panel. Copy the whole text, or only the lines around the first line that starts with an exclamation mark.

Which error should I fix first?

The first one. After an error LaTeX guesses how to continue, and the guess often produces more errors further down that disappear once the first is fixed. Fix one error, compile again, and repeat.

What does "l.12" in the log mean?

It is the line number in the file LaTeX was reading when it noticed the problem. The text after the number is what it had read on that line. The cause can sit earlier: a missing closing brace is reported where LaTeX gives up looking for it, which may be the end of the paragraph or of the file.

Why did I get a PDF although there are errors?

Editors run LaTeX in a mode that keeps going after an error. LaTeX skips or patches the broken part and finishes the file, so the PDF exists but is wrong at those places. Treat every error as something to fix, even when the PDF looks right.

What is the difference between an error and a warning?

An error means LaTeX could not do what the source asks. A warning means it did something, but the result may not be what you want: a citation printed as a question mark, a line that sticks out into the margin, a figure that moved. Fix errors first, then look at warnings before you submit.

Is my log uploaded?

No. The log is read in your browser by rules that match the error messages. Nothing is sent to a server, and no AI model reads it.