LinuxmacOSWindows

Where Does Typst Store Packages?

Typst caches downloaded packages in the OS cache directory and looks for hand-installed ones in the data dir.

Last updated

Typst downloads packages on first use and caches them. The cache lives in typst/packages/preview under the standard cache dir: ~/.cache on Linux, ~/Library/Caches on macOS, %LOCALAPPDATA% on Windows. Run typst info and read the package cache path line if yours differs, which happens with Snap installs and custom env vars.

Local packages you install by hand go somewhere else: typst/packages under the data dir (~/.local/share, ~/Library/Application Support, %APPDATA%). That split is deliberate. Cache is disposable downloads. Data is your own. Set TYPST_PACKAGE_CACHE_PATH or TYPST_PACKAGE_PATH to move either.

Where Typst stores this, by platform

Linux
~/.cache/typst/packages

Preview downloads land in preview/ beneath. Respects $XDG_CACHE_HOME. Local hand-installed packages go to ~/.local/share/typst/packages instead.

macOS
~/Library/Caches/typst/packages

Same preview layout. Local packages go to ~/Library/Application Support/typst/packages. Use Go to Folder in Finder since Library is hidden.

Windows
%LOCALAPPDATA%\typst\packages

Preview downloads beneath. Local packages go to %APPDATA%\typst\packages. typst info prints the effective paths when in doubt.

Frequently asked questions

How do I find my exact Typst package cache path?

Run typst info and look for the package cache path entry. It reflects Snap confinement and environment overrides, so it beats any documented default when the two disagree.

How do I install a Typst package without publishing it?

Place it under typst/packages/{namespace}/{name}/{version} in the data dir, for example ~/.local/share/typst/packages/local/tablex/0.0.8. Import it with the matching namespace and version.

Notice an outdated path? Let us know.