DEV Community

Akshay Kumar Dadheech
Akshay Kumar Dadheech

Posted on AI-assisted

Building browser-based PDF tools: upload limits, OCR, and the tradeoffs

I built PDF Tools Club, a free collection of PDF tools that processes documents locally in the browser. I am the maker. Here are two workflows and the tradeoffs behind them.

Splitting by file size requires measuring the output

A portal might allow several attachments but reject anything over 2 MB. Splitting a 10 MB PDF into five equal page ranges does not guarantee five 2 MB files. Scanned pages, embedded fonts and shared resources make page sizes uneven.

A useful approach is to serialize a candidate part, measure its bytes, and adjust the page range. If one page already exceeds the limit, splitting alone cannot solve that case.

Split to Upload Limit checks generated parts against the chosen limit. It is useful when the receiving service allows multiple attachments. It does not turn a multi-file submission into one smaller file.

An application pack needs navigation

A resume, certificates and supporting documents are easier to review when they have an intentional order and a contents page.

Application Pack combines PDFs with clickable contents and page numbers. After exporting, click each contents entry to check its destination, then check page orientation and readability.

The browser architecture

The site uses vanilla JavaScript and static HTML, with pdf-lib for PDF operations, PDF.js for rendering and text extraction, and Tesseract.js for OCR. Web Workers support heavier processing.

Local document processing avoids uploading PDFs to a processing server, but memory and CPU usage belong to the device. The current total input limit is 50 MB. The website still makes network requests to load its resources; local processing is not a claim that no network traffic exists.

Tradeoffs worth making visible

  • OCR needs review. English OCR supports up to 30 selected pages. Decorative artwork and poor scans can produce incorrect characters. Check names, dates and numbers.
  • Compression has different costs. Structural rewriting may save little space. Rendering pages as images can reduce some files but removes selectable text and can lose links and interactive forms.
  • Text comparison has a boundary. Side-by-side text differences do not detect every visual or image change.
  • A visual signature is not a cryptographic digital signature.
  • Annotation is not secure redaction. Covering text visually should not be treated as removing the underlying information.

There are currently 33 free tools, including merging, splitting, existing PDF form filling and annotation, with no account required.

I would value feedback on the application-pack workflow and upload-size limits. What PDF task still takes you several separate steps today?

Top comments (0)