Free
For testing and side projects
$0forever
No credit card
No overage charges
100 requests / month
Includes:
- Usage: Non-commercial
- PDF conversion
- URL conversion
- Document configuration
+ 1 more
See all 9 featuresHigh-quality HTML to PDF conversion API · by APILayer
Free plan · 100 requests / month · no card
Overview
Turn any URL or HTML into a polished PDF with one simple API. pdflayer renders HTML, CSS, JavaScript and SVG in seconds. You can add headers, footers, page numbers and watermarks without running your own conversion infrastructure.
curl --request GET \
--url "https://api.apilayer.net/pdflayer/api/convert?access_key=YOUR_ACCESS_KEY&document_url=https://example.com"
The API returns the PDF file. By default it downloads; set inline to 1 to open it in the browser.
See the response in the docsConnect to a lightweight REST API using a straightforward GET or POST request. Generate PDF documents without building your own rendering infrastructure.
Convert a standard URL directly into a PDF, or submit raw HTML for complete control over the document you're generating. Raw HTML conversion is available through HTTP POST request.
pdflayer's conversion engine is based on real browsers running powerful operating systems, allowing it to render modern web technologies and produce high-quality PDF documents.
If it renders in the browser, it renders in your PDF. pdflayer runs your page through a full browser engine, so the PDF looks like what you designed: layouts, custom fonts, charts, and dynamic content included. Send a URL or raw HTML and get back a pixel-accurate PDF.
Take control of your PDFs with more than 50 customization parameters. Configure page dimensions, margins, headers, footers, page numbers, CSS, viewport settings, rendering delays, encryption, and more.
Add customized headers and footers to your generated documents. Include branding, document information, page numbers, dates, or other dynamic elements.
Protect and brand your documents with customizable background or foreground watermark images.
Generated PDF documents are stored using pdflayer's CDN, allowing previously generated documents to be retrieved within milliseconds without counting the retrieval toward your API usage.
The pdflayer infrastructure is designed to process thousands of PDF conversion requests at a time, making it suitable for everything from individual document generation to high-volume production workflows.
From invoices and reports to contracts and receipts, pdflayer turns your web content into ready-to-share PDFs automatically.
Explore Use CasesExplore the interactive docs, endpoints, parameters, response examples and integration guides. Learn to convert URLs and HTML, customize layouts, add headers, footers and watermarks, and generate PDFs programmatically.
View DocumentationPricing
Whether you're testing PDF generation, building a document workflow, or processing large volumes of PDFs, choose the plan that matches your application.
For testing and side projects
$0forever
No credit card
No overage charges
100 requests / month
Includes:
+ 1 more
See all 9 featuresFor your first live product
$9.99/ month
Billed monthly
Then $0.03996 per extra request, up to 2,000 extra a month
1,000 requests / month
Everything in Free, plus:
For growing traffic
$39.99/ month
Billed monthly
Then $0.015996 per extra request, up to 20,000 extra a month
10,000 requests / month
Everything in Starter, plus:
For high volume
$119.99/ month
Billed monthly
Then $0.0047996 per extra request, up to 200,000 extra a month
100,000 requests / month
Everything in Professional, plus:
Need more? Contact sales for custom needs.
| 9 features | Free$0Get free key | Starter$9.99/moSubscribe | Professional$39.99/moSubscribe | Enterprise$119.99/moSubscribe |
|---|---|---|---|---|
| Usage | Non-commercial | Commercial | Commercial | Commercial |
| PDF conversion | ||||
| URL conversion | ||||
| HTML conversion | – | – | ||
| Document configuration | ||||
| Full customization parameters | – | |||
| HTTPS encryption | 256-bit | 256-bit | 256-bit | 256-bit |
| Support | – | Standard | Standard | Standard |
| Custom solutions | – | – | – | – |
| Price per extra request after the monthly limit | None | $0.03996 | $0.015996 | $0.0047996 |
Playground
Build a request in your browser and see the response it returns.
Agents
Steps for AI coding agents that add Pdflayer to a project.
A person creates the account: an agent cannot sign up. Sign up at app.apilayer.com and subscribe to Pdflayer. The Free plan includes 100 requests / month and needs no credit card.
Copy the API key from the APILayer dashboard and give it to the agent as an environment variable (step 2).
Read the key from an environment variable named APILAYER_ACCESS_KEY. Do not write the key into source code, commit it to git, or paste it into a chat.
Call Pdflayer from server code. The key travels in the request URL, so a request sent from a browser shows the key to every visitor.
# add .env to .gitignore
APILAYER_ACCESS_KEY=your_api_keyhttps://api.apilayer.net/pdflayer/apiaccess_key query parameter/convert Convertcurl "https://api.apilayer.net/pdflayer/api/convert?access_key=$APILAYER_ACCESS_KEY&document_url=https://example.com"The API info tab shows the response this request returns.
Each plan adds features to the plan before it. Check that the account's plan includes a feature before writing code that uses it.
| Plan | Requests / month | Adds |
|---|---|---|
| Free | 100 | Usage: Non-commercial, PDF conversion, URL conversion, Document configuration, HTTPS encryption: 256-bit |
| Starter | 1,000 | Usage: Commercial, Full customization parameters, Support: Standard |
| Professional | 10,000 | HTML conversion |
| Enterprise | 100,000 | Same features as Professional |
Prices are in the Pricing tab.
FAQs
Here are the answers you might be seeking
pdflayer is a REST API that converts any URLs or HTML into high-quality PDF documents. It is designed for developers and businesses that need to generate PDFs programmatically from web content.
Yes. You can use the document_url parameter to provide a URL that pdflayer will convert into a PDF document. URL conversion can be performed using GET or POST requests.
Yes. You can submit raw HTML using the document_html parameter. Raw HTML conversion is available through the HTTP POST method.
Yes. pdflayer supports both HTTP GET and HTTP POST. Some advanced functionality and parameters are available through POST only.
pdflayer can render HTML, CSS, JavaScript, XML, SVG, images, and other browser-compatible content. Its PDF engine is based on real browsers running on powerful operating systems.
Yes. pdflayer provides more than 50 customization parameters, including page dimensions, margins, CSS, viewport settings, rendering delays, encryption, page numbers, headers, footers, and more.
Yes. Headers and footers can be customized and added to generated PDF documents.
Yes. You can specify customizable background or foreground watermark images for generated PDF documents.
Yes. pdflayer is designed for automated document generation and can be integrated into workflows such as invoices, reports, receipts, certificates, statements, and other web-based documents.
After conversion, the generated PDF can be accessed through the API. pdflayer also stores generated PDF documents using a CDN, allowing existing documents to be retrieved within milliseconds.
The pdflayer API was built to provide a simple, fast and cost-effective REST API for developers and businesses to automate the process of converting HTML or HTTP URLs to high quality PDF documents. Integrating the pdflayer REST API into your application using any programming language (e.g. PHP, Python, Ruby, jQuery.ajax, Java, etc.) will enable you to generate thousands of PDF documents on the fly, making use of a full-featured suite of document configuration and customization options.
No. According to pdflayer's FAQ, retrieving an already generated PDF from its CDN does not count toward your monthly API usage.
Paid subscription plans include 256-bit HTTPS encryption for secure data transmission.
pdflayer states that its API uptime is around 99.9%, with its system status monitored around the clock.
Yes. Using the API's document_url parameter the API can be requested to generate a PDF document from a standard HTTP URL. Using the document_html parameter you can request the API to convert raw HTML code to a PDF document. Please note that converting raw HTML code is only available via HTTP POST.
You can learn more by taking a look at the pdflayer API documentation.
Every registered user is assigned a personal Access Key, a unique "password" that can be used to access and query the pdflayer API. If you are logged in, you can find it in your Account Dashboard and in all interactive links contained in the API's Documentation.
In your Account Dashboard you can reset your Access Key at any given time.
A key factor to this API's pricing model is the number of monthly API Requests offered for each individual Subscription Plan. Requesting the API to generate one PDF will increment your monthly request volume by 1 API request. Any PDF documents generated by the pdflayer API are stored using a powerful CDN, making it possible to access existing PDF documents within just a few milliseconds. Accessing an already generated PDF will not count towards your monthly API usage.
Yes. The Free plan provides 100 API requests per month and is intended for non-commercial use.
Yes. If you choose annual billing, the total price of your subscription plan will be up to 15% lower than the total amount you would pay with a monthly payment frequency.
If your usage consistently surpasses the set limits each month, you may face additional charges for the excess usage. Nevertheless, as your monthly usage reaches a certain threshold, it becomes more practical to consider upgrading to the next plan. By doing so, you ensure a smoother and more accommodating experience for your growing customer base.
pdflayer sends notifications when you reach 75%, 90%, and 100% of your monthly allowance. After reaching the included quota, overage fees apply so applications can continue running without interruption.
Users will be automatically notified via e-mail and on their Account Dashboard once at least 75%, 90%, and 100% of their monthly API Request allowance has been reached. After reaching 100% of the allowance, overages fees will apply so we make sure you won’t experience any disruptions and your website/application will keep running smoothly.
An overage occurs when you go over a quota for your API plan. When you reach your API calls limit, we will charge you a small amount for each new API call so we can make sure there will be no disruption in the service we provide to you and your website or application can continue running smoothly.
Prices for additional API calls will vary based on your plan.
Overage fees allow customers to continue using an API once a quota limit is reached. We want to make sure your website or application continues running at all times, so charges will apply if you go over your monthly quota limit. If you notice you are going over your quota limit each month, look on your dashboard for an upgraded plan to help with larger request limits.
When you are close to reaching your API calls limit for the month, you will receive an automatic notification (at 75%, 90%, and 100% of your monthly quota). You can keep track of your quota usage to prevent overages by tracking the number of API calls you make and checking the dashboard for up-to-date usage statistics.
Still have a question?
Contact support