Skip to main content

Cross-platform document scanner: crop, perspective-correct, enhance, OCR, and combine into PDF.

Project description

Scanlite

Release License: MIT Python 3.10+

Turn photos of documents into clean, searchable PDFs.

Load scanned pages or photos from your phone, let Scanlite straighten, crop, and clean them automatically, reorder as needed, and export a single PDF with an optional OCR text layer.

Getting Started

pip install scanlite
scanlite

Or download a native installer from Releases:

Platform Download Install
Windows x64 Scanlite-0.1.1.msi Double-click; installs to Program Files with Start Menu shortcut
macOS Apple Silicon Scanlite-0.1.1.dmg Open, drag to Applications
Debian / Ubuntu scanlite-0.1.1.deb sudo dpkg -i scanlite-0.1.1.deb
Fedora / RHEL scanlite-0.1.1.rpm sudo rpm -i scanlite-0.1.1.rpm

Native installers bundle Tesseract for OCR out of the box. When installing via pip, Tesseract must be available on your system PATH for the OCR export to work.

Features

Import

  • PDF (rendered at 200 DPI), PNG, JPG, TIFF, BMP, WebP
  • Multi-page PDFs split into individual pages automatically
  • Drag-and-drop support (when tkdnd is available)

Processing

  • Auto-crop: Otsu threshold + contour detection trims to the document edge

  • Auto-perspective: Canny edge detection finds a 4-point quadrilateral and warps it flat

  • Scan enhance: three modes that produce a clean, scanner-like look:

    Mode What it does
    auto Detects page brightness; picks B&W for white pages, CLAHE for darker ones
    bw Adaptive Gaussian threshold for pure black-on-white text
    gray CLAHE contrast enhancement for photos or diagrams
  • Every operation works per-page or as a batch across all pages

  • Reset any page to its original at any time

Reorder and Manage

  • Move Up / Move Down (or arrow keys) to reorder
  • Delete to remove a page
  • Thumbnail panel shows the current page order at a glance

Export

  • PDF: combines all pages into a single document
  • PDF + OCR: Tesseract generates an invisible text layer per page, making the output searchable and copy-pasteable
  • Keyboard shortcuts: Ctrl+S export, Ctrl+Shift+S export with OCR

Keyboard Shortcuts

Key Action
Ctrl+O Import files
Up / Down Navigate pages
Delete Remove selected page
Ctrl+S Export PDF
Ctrl+Shift+S Export PDF + OCR

How It Works

Scanlite's processing pipeline runs perspective correction first (to avoid cropping a skewed quad), then crop, then enhancement. Each step is independent and can be applied or skipped per page.

The perspective detector looks for the largest 4-sided contour in the edge map and computes a homography to warp it into a rectangle. If no quadrilateral is found, the image passes through unchanged.

The scan enhancer auto-detects whether a page is mostly white (median brightness > 170) and picks adaptive thresholding for text-heavy pages or CLAHE for photos and diagrams.

System Requirements

  • Python 3.10+
  • Tesseract OCR (bundled in native installers; for pip installs, install separately)

Support

"Software is like sex: it's better when it's free." -- Linus Torvalds

If this tool saved you a trip to the copy shop, buying me a coffee is a nice way to say thanks.

Buy Me A Coffee

License

MIT (see LICENSE.md)

Citation

@software{scanlite,
  author = {Colling, Gilles},
  title = {Scanlite: Cross-Platform Document Scanner},
  year = {2026},
  url = {https://github.com/gcol33/scanlite}
}

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

scanlite-0.1.1.tar.gz (15.4 kB view details)

Uploaded Source

Built Distribution

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

scanlite-0.1.1-py3-none-any.whl (14.9 kB view details)

Uploaded Python 3

File details

Details for the file scanlite-0.1.1.tar.gz.

File metadata

  • Download URL: scanlite-0.1.1.tar.gz
  • Upload date:
  • Size: 15.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for scanlite-0.1.1.tar.gz
Algorithm Hash digest
SHA256 43db59b6e48fc31c6452e4b82d3b131e50abe8f2bf576f3d22b4f228a2431d9d
MD5 5cdda7c85eb4e70a908453a92d225e90
BLAKE2b-256 70a0fed19b7874e8c0dd0f1d63b1387bbc6a0cf376e8ae095885d73cd631790e

See more details on using hashes here.

Provenance

The following attestation bundles were made for scanlite-0.1.1.tar.gz:

Publisher: release.yml on gcol33/scanlite

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file scanlite-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: scanlite-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 14.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for scanlite-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 b6de504276b19f914630f788bc0963abd800f8f141a917d72b7f46fdd7a5d792
MD5 8e6bafcb679040aa2aa5a09ecb7e81fc
BLAKE2b-256 96a00dcee12f10e865afa46dd6c4fe0ff1f037b997d9454cec3952953fec27de

See more details on using hashes here.

Provenance

The following attestation bundles were made for scanlite-0.1.1-py3-none-any.whl:

Publisher: release.yml on gcol33/scanlite

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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