---
title: Convert HTML Content to PDF API
slug: convert-html-content-to-pdf
url: https://apyverse.com/apyhub/service/convert-html-content-to-pdf
provider: ApyHub
categories: [File Conversion]
auth: api_key
---

# Convert HTML Content to PDF API

Convert HTML content into a PDF download or signed link. Useful for invoices, reports, and other HTML-based documents.

## Endpoints

| Method | Path | Description | Atoms |
| --- | --- | --- | --- |
| POST | `generate/html-content/pdf-file` | What it does Converts the provided HTML content string into a PDF and returns the PDF as a binary r… | 50 |
| POST | `generate/html-content/pdf-url` | What it does Renders the provided HTML content string into a PDF and returns a signed link to the g… | 50 |

## About

## What it does
HTML to PDF renders an HTML content string into a PDF, either as a direct download or as a signed link you can fetch later. Send the HTML in `body.content`, and choose whether the output should be landscape with the `landscape` query parameter.

Use `POST /download` when you want a PDF binary response immediately. Use `POST /link` when you want a URI in the `data` field instead. That makes it easy to separate generation from delivery in workflows where you store, queue, or pass around the file later.

This is a good fit for generating invoices, reports, receipts, or any page-like document from server-side HTML. Because the input is raw HTML, you can render your own templates and control layout before converting them to PDF.

The service keeps the interface simple: one required HTML payload, one optional layout flag, and two output modes depending on whether you need the file now or a signed link.

## Usage

Authenticate with an ApyHub API key in the `apy-token` header.
Full docs and a live playground: https://apyverse.com/apyhub/service/convert-html-content-to-pdf
