Skip to main content

A lightweight, self-hosted Overleaf alternative — zero-dependency LaTeX web editor

Project description

tinyleaf

Tinyleaf

PyPI version GitHub release CI License: AGPL v3 Documentation

中文版 | Documentation | Brand assets

Tinyleaf is a tiny, local-first TeX editor that runs in your browser.

It is built for people who want an Overleaf-like editing experience without running a full Overleaf stack. Install one Python package, point it at a LaTeX project, and edit from a clean web UI with PDF preview, compile logs, Git tools, search, outline, and multi-tab editing.

pip install tinyleaf

# Open one project. Docker-based TeX Live compilation is enabled by default.
tinyleaf /path/to/my-thesis

# Or use a local TeX installation instead.
tinyleaf /path/to/my-thesis --no-docker

# Launch the project registry.
tinyleaf

Why Tinyleaf?

Tinyleaf sits between a local editor and a full collaborative LaTeX platform:

  • Local-first — your projects stay on your filesystem
  • Self-hosted — run it on your laptop, workstation, lab server, or VPS
  • Small runtime — no database, no Node.js service, no Redis, no MongoDB
  • Browser UI — CodeMirror editor, PDF preview, file tree, Git panel, and settings
  • Flexible compilation — Dockerized TeX Live by default, or local latexmk with --no-docker
  • Single-user focused — designed for individual writing workflows, not a multi-user SaaS clone

Features

Editing

  • CodeMirror 6 editor with LaTeX syntax highlighting
  • Multi-tab editing with quick open (Ctrl+P)
  • Auto-pair \begin{...} / \end{...}
  • Project-wide search
  • LaTeX outline sidebar with recursive \input / \include support
  • \ref{}, \cite{}, and \label{} autocomplete from project symbols

PDF and compilation

  • PDF.js preview with live reload
  • Page navigation, zoom controls, and text search
  • Real-time compile logs over SSE
  • Clickable file.tex:line entries in compile output
  • SyncTeX forward/reverse search
  • Word/page statistics via texcount
  • Export project as ZIP

Projects and workflow

  • Single-project mode: open any directory directly
  • Multi-project registry stored at ~/.config/tinyleaf/projects.json
  • File tree with create, upload, rename, delete, and search
  • Git status, diff, commit, push, pull, and log from the UI
  • 7 UI themes with light/dark mode
  • English and Chinese UI

Installation

pip install tinyleaf

Tinyleaf has zero Python runtime dependencies beyond the standard library. The web editor assets are bundled with the package.

For compilation, choose one of:

Backend Command Requirements
Docker TeX Live tinyleaf /path/to/project Docker installed
Local TeX Live tinyleaf /path/to/project --no-docker latexmk available in PATH

Usage

usage: tinyleaf [-h] [-V] [--projects-dir DIR] [--config-dir DIR]
                [--docker | --no-docker] [--image IMAGE] [--port PORT]
                [--host HOST] [--no-browser]
                [project_path]

Common examples:

# Open a project and compile with Docker.
tinyleaf ~/papers/my-paper

# Use local latexmk instead of Docker.
tinyleaf ~/papers/my-paper --no-docker

# Bind to all interfaces on a server.
tinyleaf ~/papers/my-paper --host 0.0.0.0 --port 14159

# Start the multi-project registry view.
tinyleaf

Multi-project registry

When launched without a project_path, Tinyleaf opens a project registry. The registry maps project names to absolute paths anywhere on the filesystem.

From the project page you can:

  • Open Folder — register an existing directory
  • New Project — create a new project at a chosen location
  • Remove — unregister a project, optionally deleting files
  • Switch views — grid/list layout with persistent preferences

Keyboard shortcuts

Shortcut Action
Ctrl+S Save current file
Ctrl+Enter Compile
Ctrl+P Quick open
Ctrl+Shift+F Project search
Ctrl+Shift+C Git commit
Ctrl+Shift+P Git push
Ctrl+/ Shortcut help

Docker Compose

For a simple containerized setup:

docker compose up

Tinyleaf starts at http://localhost:14159.

Tinyleaf vs. Overleaf CE

Tinyleaf Overleaf CE
Primary use case Personal/local TeX editing Multi-user collaborative platform
Install pip install tinyleaf Docker Compose stack
Runtime services Python stdlib server MongoDB, Redis, Node.js, CLSI, etc.
Project storage Your filesystem Application-managed storage
Compilation Docker TeX Live or local latexmk CLSI service
Git workflow Built-in lightweight UI Git Bridge
Collaboration Single-user focused Multi-user

Tinyleaf is not trying to replace the full Overleaf collaboration model. It is for writers who want a fast, self-hosted browser editor for their own TeX projects.

Documentation

License

AGPL-3.0-or-later

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

tinyleaf-0.5.0.tar.gz (98.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

tinyleaf-0.5.0-py3-none-any.whl (98.9 kB view details)

Uploaded Python 3

File details

Details for the file tinyleaf-0.5.0.tar.gz.

File metadata

  • Download URL: tinyleaf-0.5.0.tar.gz
  • Upload date:
  • Size: 98.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for tinyleaf-0.5.0.tar.gz
Algorithm Hash digest
SHA256 35b708028f8d95b3e102bb30578ff6dc90f14eb518601fb33a8005efd541411a
MD5 9fbe3158c86dc590a119db1ffac65bf5
BLAKE2b-256 981c6d950408c1734cfe54777359cfb273d06b6ee614cc1c1e88a4a33ceeeae7

See more details on using hashes here.

File details

Details for the file tinyleaf-0.5.0-py3-none-any.whl.

File metadata

  • Download URL: tinyleaf-0.5.0-py3-none-any.whl
  • Upload date:
  • Size: 98.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for tinyleaf-0.5.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9b3d54218520b114efdacd0965c5223e4080942df936a4f0c84bbd61e511d54b
MD5 1ad6d60a5a486cc8f032e1f5b063ba70
BLAKE2b-256 266f01508ac1c9e4a5d22d65f34ee11deb7e2cf05649d003aa20f63b0158f898

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page