TeXstudio is a free, open-source LaTeX IDE for Windows, macOS, and Linux. Editor, PDF viewer, build configuration, and completion live in one window, and it drives a TeX distribution (such as TeX Live) that you install separately. This page focuses on the three things that matter most in practice: the build configuration people get stuck on, the completion that speeds up writing, and SyncTeX for jumping between source and PDF.
What TeXstudio is
TeXstudio is a dedicated LaTeX editor that began as a fork of the older Texmaker codebase. Built on Qt, it looks and behaves almost identically across the three operating systems, and it offers syntax highlighting, live spell- and grammar-checking, a palette of 400-plus math symbols, and a built-in PDF viewer. Note that it does not bundle LaTeX itself: compilation works by having TeXstudio launch commands such as pdflatex or latexmk that are already installed on your system.
So the order of installation matters: install a TeX distribution first, then TeXstudio. Once a working setup is in place (e.g. TeX Live 2026), all that remains on the TeXstudio side is to wire up how it builds your document.
Build configuration
All settings live under Options → Configure TeXstudio. Ticking “Show Advanced Options” at the bottom reveals many more entries. Two tabs govern building: the Build tab decides *which* command is the default, and the Commands tab specifies *what* each command actually is — the path to the executable and its arguments.
In daily use you only need two buttons. Build & View (F5) compiles and then opens the PDF; Compile (F6) just produces the PDF. Beyond those, View (F7) opens the PDF, and Clean sweeps away intermediate files such as .aux and .toc.
Internally, each action is expressed as a command beginning with txs:///. For example txs:///compile is “the default compiler,” txs:///view is “the default viewer,” and txs:///latexmk is latexmk. “Build & View” is simply a sequence of such commands joined by the pipe |. The default compiler ships as pdfLaTeX, but a common move is to switch it to latexmk, which automatically handles dependencies — bibliography, index, and the number of reruns.
Writing the latexmk line in the Commands tab like the following produces a PDF directly and emits SyncTeX information at the same time. The % expands to the file being processed (without extension):
latexmk -pdf -synctex=1 -interaction=nonstopmode %.texWhen you want to switch engines per document, a magic comment on the first line does it. The single line below, for instance, makes just that document compile with LuaLaTeX:
% !TeX program = lualatexConfiguring builds for Japanese
Two approaches are widely used for Japanese. One is LuaLaTeX: in the Build tab, set Build & View to “Compile & View” and the default compiler to “LuaLaTeX,” and a single press of F5 takes you to the PDF. For a fresh start this is the straightforward choice. The other is upLaTeX + dvipdfmx, long the standard for Japanese: there you set Build & View to the “DVI->PDF chain” and the default compiler to “LaTeX” (because it goes by way of a DVI before the PDF).
The cleanest arrangement is to describe the engine combination in a **.latexmkrc** and let TeXstudio merely call latexmk. Place the following file in the same folder as your .tex, and latexmk takes care of the upLaTeX → dvipdfmx flow, the bibliography (upbibtex), the index (upmendex), and the rerun count. Because $latex includes -synctex=1, SyncTeX works too:
$latex = 'uplatex %O -synctex=1 -interaction=nonstopmode %S';
$bibtex = 'upbibtex %O %B';
$makeindex = 'upmendex %O -o %D %S';
$dvipdf = 'dvipdfmx %O -o %D %S';
$pdf_mode = 3;Here $pdf_mode = 3 selects the mode “make a DVI, then turn it into a PDF with $dvipdf.” The tokens %O (extra options), %S (the source file), %B (the base name without extension), and %D (the output target) are latexmk’s placeholders. With this approach you get the same result whether you invoke it from TeXstudio, the command line, or another editor — the configuration lives in one place.
Completion and the structure view
TeXstudio’s completion reliably cuts keystrokes. Typing \ followed by a letter pops up a list of candidate commands, narrowing as you add letters; when several candidates share a common prefix, Tab fills in that shared part at once. Better still, writing a cross-reference \ref{...} offers the labels present in the document, and \cite{...} offers the bibliography keys (bibIDs) — so you rarely have to half-remember a name.
Environments are pleasant to work with, too. Begin one — say \begin{itemize} — and the matching \end{itemize} is inserted automatically. Rest the cursor on an existing environment name for a moment and a mirror cursor appears, letting you rewrite the names in \begin and \end simultaneously (changing itemize to enumerate in one move). To close whatever environment is still open, press Alt+Return.
The Structure view on the left becomes a map of your document. It lists headings (\section and friends), labels (\label), the files pulled in via \input/\include, beamer blocks, and TODOs (\todo{} or % TODO comments); clicking an entry jumps to that spot. Even in long manuscripts or multi-file projects you keep sight of the whole.
SyncTeX (forward and inverse search)
SyncTeX maps source lines to positions in the PDF and back. With it working, you get forward search — jumping from the line you are on in the editor to the matching place in the PDF — and inverse search, jumping back from a spot in the PDF to the corresponding source line. It pays off when proofreading: the hunt for “which line produced this paragraph” simply disappears.
Two conditions enable it. First, pass **-synctex=1** to the compile command so a synchronization file (.synctex.gz) is produced — the latexmk line and .latexmkrc above already do this, and if you forget, TeXstudio offers to correct the command for you. Second, open the PDF in the internal PDF viewer; its SyncTeX support is what makes the two-way jumps possible.
The gestures are simple. Forward search runs automatically to your current cursor position each time the viewer opens; to trigger it anywhere, Ctrl + left-click in the source or choose “Go To PDF” from the context menu. For inverse search, Ctrl + left-click on text in the PDF, or pick “jump to source” from the right-click menu. Enabling “scrolling follows cursor” and “cursor follows scrolling” keeps the two linked continuously as you edit.