npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@kukhta_stepan/n8n-nodes-pdf-to-images

v1.0.9

Published

n8n community node: PDF binary → JPEG/PNG per page (Mozilla PDF.js + @napi-rs/canvas, no MuPDF/Poppler)

Downloads

815

Readme

@kukhta_stepan/n8n-nodes-pdf-to-images

Professional n8n community node for document/image conversion to raster output, powered by pdfjs-dist and @napi-rs/canvas (no MuPDF or Poppler required).

What This Node Does

The node supports three practical workflows:

  1. PDF -> JPG/PNG (page-by-page)
  2. RTF -> JPG/PNG (page-by-page)
  3. Image -> JPG (for PNG/JPEG/GIF/WebP/BMP inputs)

Node Details

  • Display name: PDF to Images
  • Node name: pdfToImagesPdfJs
  • Type version: 3
  • Input: binary data field (configured by Binary Field Name)
  • Output: one or more items with generated image binaries plus metadata in json

Operations

1) PDF/RTF -> images (each page)

This is the main operation for document conversion.

  • Input type is auto-detected inside this mode:
    • %PDF- signature -> handled as PDF
    • {\rtf signature -> handled as RTF
  • Output format:
    • JPEG (smaller files)
    • PNG (lossless)
  • DPI controls page render scale and output size.

If the file is neither valid PDF nor RTF, the node returns a clear validation error.

2) Image -> JPEG

Converts one raster image to one JPEG image.

  • Supported inputs: PNG, JPEG, GIF, WebP, BMP
  • Useful for PNG -> JPG normalization before OCR/storage pipelines.

Output Metadata

For each produced image item, json includes:

  • conversionMode
  • sourceType (pdf, rtf, or image)
  • page, totalPages
  • fileName, format, dpi (when applicable)
  • width, height
  • binaryKey, binaryField, binaryPrefix, binaryPageIndex

Binary Field Naming Rules

Output Binary Field (prefix) controls output key naming in item.binary.

  • Prefix is set
    Keys are always indexed: {prefix}0, {prefix}1, {prefix}2, ...

  • Prefix is empty
    The node preserves the resolved input binary field name (per item). Fallback order:

    1. Resolved Binary Field Name value
    2. $json.binaryPropertyName
    3. data

For multi-page PDF/RTF with empty prefix:

  • page 1 keeps the original name, e.g. data0
  • next pages use suffix with underscore: data0_1, data0_2, ...

This avoids accidental renaming like data0 -> data00.

Install in n8n

  1. Open Settings -> Community nodes -> Install
  2. Install package:
    • @kukhta_stepan/n8n-nodes-pdf-to-images
  3. Reload n8n if prompted

Self-hosted environments must allow community packages (for example N8N_COMMUNITY_PACKAGES_ENABLED).

Local Development

npm install
npm run build

Publish (Maintainers)

npm login
npm version patch
npm publish --access public

Notes:

  • package is scoped, so --access public is required
  • prepack runs npm run build automatically

License

MIT