PDFMunk logo+n8n logo
    Native Integration

    HTML to PDF in n8n Workflows

    Use the official PDFMunk n8n node to convert HTML, CSS, and URLs into pixel-perfect PDFs — without writing a single line of code.

    What is n8n?

    n8n is a powerful open-source workflow automation tool that lets you connect apps, APIs, and services without code. With over 400 native integrations and a visual drag-and-drop editor, teams use n8n to build automation that runs 24/7 — on their own infrastructure or in the cloud.

    By combining n8n with PDFMunk, you can trigger PDF generation from any event — a new form submission, a Stripe payment, a CRM update — and route the finished document wherever you need it.

    400+ integrations
    Self-hostable & secure
    Code or no-code
    Scheduled & event-driven
    Supported Operations

    Everything you can do with PDFMunk + n8n

    Two powerful operations cover every PDF automation scenario your workflow demands.

    HTML to PDF

    Convert raw HTML and CSS markup into a pixel-perfect PDF document. Supports inline styles, external stylesheets, custom fonts, and complex layouts.

    • Custom page size (A4, Letter, A3, A5, Legal)
    • Portrait or Landscape orientation
    • Custom margins (top, right, bottom, left)
    • Header & footer HTML templates
    • Print background graphics toggle
    • Viewport width configuration

    URL to PDF

    Capture any public webpage URL as a high-fidelity PDF — ideal for archiving reports, generating invoices from web pages, or snapshotting dashboards.

    • Full-page screenshot capture
    • Wait for network idle / DOM ready
    • Custom viewport dimensions
    • Page scale factor
    • Cookie & header injection
    • JavaScript execution support

    Full Configuration, Zero Code

    Every PDFMunk option is exposed as a configurable field directly inside your n8n workflow — no custom API calls required.

    OptionAvailable Values
    Page FormatA4, A3, A5, Letter, Legal, Tabloid
    OrientationPortrait, Landscape
    MarginsTop, Right, Bottom, Left (in mm or px)
    Header HTMLCustom HTML template with page number & total pages
    Footer HTMLCustom HTML template with page number & total pages
    Print BackgroundEnable or disable background colors and images
    Scale0.1 – 2 (default: 1)
    Wait Untilload, domcontentloaded, networkidle0, networkidle2
    Quick Setup

    Get started in 4 steps

    From zero to automated PDF generation in minutes.

    01

    Install the PDFMunk node

    Open your n8n instance and go to Settings → Community Nodes. Search for "PDFMunk" and click Install. The node will appear in your workflow palette immediately.

    02

    Add your API credentials

    In n8n, navigate to Credentials → New Credential → PDFMunk API. Paste your PDFMunk API key (found in your dashboard under API Keys) and save.

    03

    Add the PDFMunk node to a workflow

    Drag the PDFMunk node into your canvas. Choose an operation — "HTML to PDF" or "URL to PDF" — and configure the page settings to match your document requirements.

    04

    Connect and automate

    Wire PDFMunk between your trigger (webhook, schedule, CRM event) and downstream nodes (email, Google Drive, S3). Activate the workflow and your PDF generation runs on autopilot.

    Or call the API directly

    Prefer to use the PDFMunk REST API from an n8n HTTP Request node? Simply POST your HTML payload to our endpoint and receive a PDF binary in the response — ready to pass to any downstream node.

    Read API Docs
    n8n HTTP Request node
    POST https://api.pdfmunk.com/pdf
    Authorization: Bearer YOUR_API_KEY
    Content-Type: application/json
    
    {
      "html": "<h1>Hello, PDF!</h1>",
      "options": {
        "format": "A4",
        "landscape": false,
        "margin": {
          "top": "20mm",
          "right": "15mm",
          "bottom": "20mm",
          "left": "15mm"
        },
        "printBackground": true
      }
    }
    Use Cases

    What teams automate with PDFMunk + n8n

    From invoices to certificates, any workflow that produces a document can benefit from automated PDF generation.

    Automated Invoice Generation

    Trigger on new Stripe payment → build HTML invoice → convert to PDF with PDFMunk → email to customer via Gmail or SendGrid.

    Report Archiving

    Schedule nightly jobs that snapshot analytics dashboards from URLs, convert them to PDF, and store them in Google Drive or S3 for auditing.

    CRM Document Workflows

    On deal closed in HubSpot or Pipedrive, generate a signed contract PDF from an HTML template and attach it directly to the CRM record.

    Web Page Snapshots

    Capture competitor pages or internal dashboards on a schedule, convert them to PDF, and send a digest email to your team every morning.

    Dynamic Certificate Creation

    On course completion in your LMS, render a personalised certificate HTML template and produce a downloadable PDF in seconds.

    E-commerce Order Slips

    Convert Shopify/WooCommerce order confirmation HTML emails to PDF packing slips and route them to your warehouse management system automatically.

    Why choose PDFMunk for n8n?

    Blazing Fast

    PDFs are generated in under 2 seconds on average, so your workflows never bottleneck on document creation.

    99.9% Uptime SLA

    Built on a global CDN with redundant infrastructure — your automations keep running around the clock.

    Pixel-Perfect Output

    Chromium-based rendering ensures your PDFs look exactly like the HTML you send, fonts and all.

    Frequently asked questions

    Ready to automate your PDF workflows?

    Sign up for free and start converting HTML to PDF inside your n8n workflows today — no credit card required.

    PDFMunk n8n Integration – HTML to PDF in n8n Workflows

    Integrate PDF Munk with n8n to automate document generation from your workflows. This page is part of the PDF Munk API platform used for document generation and processing workflows such as HTML to PDF, URL capture, image conversion, OCR, merging, splitting, compression, watermarking, and secure file lifecycle controls.

    Developers typically start with interactive tests, then move the same payloads into backend services, scheduled jobs, and workflow automation tools. You can use this route to validate request structure, evaluate response behavior, and confirm output quality before production rollout.

    Canonical URL: https://pdfmunk.com/n8n-integration. For implementation guidance, review API Docs, run examples in Try Now, and check integration references for n8n and Zapier on the tutorials and blog pages.

    Common production patterns include generating invoices from HTML templates, capturing webpages for legal records, extracting searchable text from scanned files, transforming PDF pages into preview images, and combining or splitting files in approval workflows. Teams often pair these endpoints with queue workers, idempotent retry logic, and structured logging so conversion jobs remain reliable during traffic spikes and downstream API delays.

    When implementing this route, validate input payloads early, keep output mode consistent per workflow, and add monitoring for latency, error rates, and response integrity. For sensitive documents, enforce least-privilege API key handling, rotate credentials periodically, and delete temporary files using lifecycle endpoints once processing is complete. These operational practices improve reliability, security, and cost control as document volume grows.

    Implementation checklist for teams

    Before going live, define request validation rules, decide whether responses should return files or URLs, and set clear retry behavior for network failures. Use consistent timeout values across services, track request IDs end-to-end, and record conversion outcomes for auditing. In batch workflows, split large jobs into smaller units so retries are cheaper and easier to reason about. If you process user-uploaded files, normalize inputs, enforce file-size limits, and surface actionable error messages when payloads are invalid or inaccessible.

    For SEO and rendering quality, keep templates deterministic, pin fonts where possible, and test with representative documents instead of only minimal samples. Add smoke tests for key paths such as create, transform, OCR, and delete operations. If your business depends on predictable output formatting, run visual regression checks on generated documents and store known-good fixtures. These practices reduce operational surprises and help teams maintain stable document automation as APIs, templates, and customer data evolve.

    Need a practical starting point? Begin with a single route, ship observability first, then expand endpoint coverage incrementally. Most teams achieve faster rollout by standardizing request wrappers, centralizing credential handling, and documenting common payload patterns for engineers and no-code operators alike.