October DealsAmazon USOctober deal check: compare before you payAmazon US: current deals, useful picks and tech finds.Check DealsPC HealthRecommendedCrashes, freezes, slowdowns? Check your PC nowSpot repairable issues before they interrupt work.Check PCOctober DealsAmazon USDeal season is back - check today's better picksAmazon US: current deals, useful picks and tech finds.See Picks×
Skip to content
World desk4 min

Jupyter Notebook to PDF: Fix Missing TeX and Export Errors

Choose the right Jupyter-to-PDF route for your setup: TeX-based nbconvert, Chromium WebPDF, browser printing, VS Code, or your notebook app's export menu.
Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

To convert a Jupyter notebook to PDF, choose a renderer that matches your setup: use nbconvert --to pdf if you have TeX, nbconvert --to webpdf if you can use Playwright and Chromium, or export HTML and print it from a browser if you want browser print controls. VS Code and notebook-app menus offer convenient GUI routes, but their availability and requirements vary.

Choose a PDF export method

Method Rendering route Main requirement Best fit
nbconvert PDF LaTeX with XeTeX A functioning TeX installation, including required packages and fonts Repeatable exports or LaTeX template control
nbconvert WebPDF HTML rendered by headless Chromium nbconvert’s WebPDF extra and Playwright browser support A browser-based export without a TeX toolchain
HTML, then browser print HTML rendered and printed by a browser An HTML-capable browser Print-dialog controls, including a workaround for SVG-only outputs in VS Code
VS Code Export PDF Direct PDF export TeX One-off export while working in the notebook editor
Notebook app Download as / Export Depends on the frontend and configured exporter A PDF option in the installed application and its required backend A convenient GUI entry point

The first three routes are available as explicit nbconvert workflows. nbconvert’s command-line documentation describes PDF, WebPDF, and HTML output; its Notebook web application Download as feature is also implemented through nbconvert. The menu is therefore a frontend to conversion, not necessarily an independent PDF engine. See nbconvert command-line usage and nbconvert documentation.

As an Amazon Associate I earn from qualifying purchases.

Method 1: Convert with nbconvert and TeX

Use this route if TeX is already installed, or if you need the LaTeX templates and rendering controls. Open a terminal in the directory containing the notebook and run:

Free tools Windows power users keep installed

One-click scans. No signup required.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
jupyter nbconvert --to pdf notebook.ipynb

Replace notebook.ipynb with your file’s name. The PDF exporter uses the LaTeX route with XeTeX. A complete TeX installation can take substantial space; nbconvert’s installation documentation names TeX Live for Linux, MacTeX for macOS, and the LaTeX Project distribution for Windows. Missing TeX packages or fonts can stop conversion. See the nbconvert installation guide.

If conversion fails

If the error reports a missing executable, check that XeLaTeX is available in your environment and that the required TeX packages and fonts are installed. To inspect or adjust the generated source, export to LaTeX first and run XeLaTeX manually; this separates notebook conversion from PDF compilation. The nbconvert command options and formats are documented in its command-line guide.

Method 2: Use nbconvert WebPDF without TeX

WebPDF renders the notebook to HTML, then uses headless Chromium to create the PDF. It avoids a TeX toolchain but requires Playwright’s browser automation support.

  1. Install the WebPDF extra:
    pip install "nbconvert[webpdf]"
  2. From the notebook’s directory, run:
    jupyter nbconvert --to webpdf notebook.ipynb
  3. If Playwright cannot find a suitable browser, follow nbconvert’s documented Chromium setup and use --allow-chromium-download when needed.

Choose this when Chromium-based rendering suits your notebook and installing the browser dependency is practical. The steps and option are documented in the nbconvert usage guide and installation guide.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

Method 3: Export HTML and print it to PDF

This method keeps HTML conversion separate from PDF printing, so you can use your browser’s print controls.

  1. Create an HTML file:
    jupyter nbconvert --to html notebook.ipynb
  2. Open the generated HTML file in a browser.
  3. Open the browser’s Print command and choose the browser or operating system’s Save as PDF option.

Inspect the resulting PDF for page breaks, wide tables, code wrapping, and image scaling. Visual Studio Code recommends this route for notebooks with SVG-only outputs because its direct PDF export does not display those outputs. See Microsoft’s Jupyter notebooks in VS Code guide.

Method 4: Export PDF from VS Code

In the notebook editor, open the main toolbar’s … menu, choose Export, then choose PDF. Microsoft’s notebook guide says this direct export requires TeX and warns that SVG-only notebook outputs will not display in the PDF. If those outputs matter, use the HTML-and-browser-print route instead. The exact commands and caveat are in the VS Code notebook guide.

Method 5: Use the notebook application’s Download as or Export menu

If your installed notebook application offers Download as or Export to PDF, that is often the quickest GUI route for an occasional conversion. The exact label and available formats depend on the frontend and version. Since the Notebook web application’s Download as feature is implemented by nbconvert, the menu can depend on the exporters and dependencies available in its configured environment. If PDF is missing from the menu or the export fails, use an explicit nbconvert command instead. See nbconvert documentation.

What’s actually slowing this PC down?

Pick the symptom - the matching free tool is one click away.

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Support on Ko-Fi

Check the PDF before sharing it

  • Confirm that plots, images, and rich outputs appear, especially if the notebook contains SVG-only plots and you used VS Code’s direct export.
  • Review page breaks and page orientation for wide tables or long code cells.
  • Check that code and output are readable and that images have not been clipped or scaled too small.
  • If the layout is poor, try a different rendering path: LaTeX/XeTeX, WebPDF/Chromium, or HTML and browser printing use different pipelines.

For a general overview of notebook conversion formats, see Jupyter’s formatting and conversion documentation.

Product prices and availability are accurate as of the date/time indicated and are subject to change. Any price and availability information displayed on Amazon at the time of purchase will apply.

Leave a Reply

Your email address will not be published. Required fields are marked *

Special offer. See more information about Outbyte and uninstall instructions. Please review EULA and Privacy policy.

More from the Wire

  1. World desk4 min
    How to Spot an AI Voice Scam Before Sending MoneyDon’t rely on how a caller sounds. Pause, call back through a known number, and verify the emergency with another trusted person before sending money.
  2. Mountain View desk4 min
    Google’s SynthID Detector: How to Check AI-Generated Images, Video and AudioGoogle’s SynthID Detector looks for an embedded watermark in supported images, video and audio. Here is what its results do—and do not—show.
  3. Redmond desk20 min
    How to create a link to File or Folder in Windows 11Windows 11 gives you several ways to point to a file or folder without moving or duplicating it. You can create a desktop shortcut,…
Recommended PC Tool
Recommended PC Tool
Windows Errors? Fix Them Before They SpreadFree repair scan
Crashes, No Sound, or Screen Glitches?Free driver scan

Two free Windows tools

One Free Minute Could Fix That PC

Before you go - each of these free tools takes about a minute and tackles what quietly slows a Windows PC down.

Special offer. View Outbyte info, uninstall instructions, EULA, and Privacy Policy.