Convert PDF to Image API
Send a PDF URL and get one image per page back, as PNG, JPEG or TIFF, at the resolution and in the color mode you choose. Made for thumbnails, previews and vision models.
- Free plan
- No credit card
Request
curl -X POST https://apdf.io/api/pdf/file/to-image \
-H "Authorization: Bearer TOKEN" \
-d file="FILE_URL" \
-d image_type="jpeg"
const data = new FormData();
data.append('file', 'FILE_URL');
data.append('image_type', 'jpeg');
fetch('https://apdf.io/api/pdf/file/to-image', {
headers: {'Authorization': 'Bearer TOKEN'},
method: 'POST',
body: data
})
.then(response => response.json())
.then(json => console.log(json));
use GuzzleHttp\Client;
$client = new Client();
$response = $client->post(
'https://apdf.io/api/pdf/file/to-image', [
'headers' => [
'Authorization' => 'Bearer TOKEN'
],
'form_params' => [
'file' => 'FILE_URL',
'image_type' => 'jpeg'
]
]);
$body = $response->getBody();
echo json_encode($body->getContents());
require 'rest-client'
response = RestClient.post(
'https://apdf.io/api/pdf/file/to-image',
{
'file' => 'FILE_URL',
'image_type' => 'jpeg'
},
{
Authorization: "Bearer TOKEN"
}
)
puts response.body
import requests
response = requests.post(
'https://apdf.io/api/pdf/file/to-image',
headers = {
'Authorization': 'Bearer TOKEN'
},
data = {
'file': 'FILE_URL',
'image_type': 'jpeg'
}
)
print(response.text)
import (
"fmt"
"github.com/go-resty/resty/v2"
)
func main() {
client := resty.New()
data := map[string]string{
"file": "FILE_URL",
"image_type": "jpeg"
}
resp, _ := client.R().
SetFormData(data).
SetHeader("Authorization", "Bearer TOKEN").
Post("https://apdf.io/api/pdf/file/to-image")
fmt.Println(resp.String())
}
import okhttp3.*;
class Pdf {
public static void main(String[] args) throws Exception {
OkHttpClient client = new OkHttpClient();
FormBody formBody = new FormBody.Builder()
.add("file", "FILE_URL")
.add("image_type", "jpeg")
.build();
Request request = new Request.Builder()
.url("https://apdf.io/api/pdf/file/to-image")
.addHeader("Authorization", "Bearer TOKEN")
.post(formBody)
.build();
Response response = client.newCall(request).execute();
System.out.println(response.body().string());
}
}
One page in.
One image out.
Every page you select is rendered to its own image file.
The response lists each file with its page number.
- image_type
- png, jpeg, jpegcmyk or tiff
- dpi
- The resolution, 150 if left out
- color_mode
- color, gray or mono for black and white
- pages
- Page 1 if left out, or a list like 1,4,6
- 1-z, r3-r1
- All pages, or the last three
Pictures of your pages.
Wherever a PDF can't be shown or read, an image of its pages can.
Thumbnails in lists
Show a small image of the first page next to every document in your app, so users recognize files at a glance.
Previews in email and chat
Put an image of the page right into the message, where a PDF attachment would need a click and a download first.
Pages for vision models
Give AI models that read images a picture of each page, with the charts, stamps and layout that plain text leaves out.
Images for the web
Publish flyers, menus and brochures as images on websites and in social posts that don't accept PDF files.
Render from anywhere.
Turn pages into images inside the tools you already use.
One account and one monthly allowance behind every route.
One authenticated POST from any language. Copy-paste samples in cURL, Node.js, Python and more.
POST /api/pdf/file/to-image
Pick the action in any Zap and map files from earlier steps. No code and no servers to run.
Convert PDF to Images
Add the Apdf node to any workflow, on n8n Cloud or self-hosted, and chain it with your automation.
Convert PDF to image
Let Claude, ChatGPT, Gemini or your own agent run it through the MCP server, on any paid plan.
convert-pdf-to-image
1,000 image conversions
a month. Free.
Start on the free plan and move up only when your volume does — up to 1,000,000 operations a month on Business.
- One call is one operation, however many pages.
- Only calls that do the work are counted.
- Hard limits, so no surprise overage charges.
PDF to image, answered
PDF to image tutorials
Generate PDF Thumbnails for Document Previews with Go
Build a document preview system by converting PDF pages to thumbnail images using Go. Learn how to generate fast, lightweight previews for file browsers and document management systems without heavy local dependencies.
How to Send "Embedded" PDF Invoice Previews in Emails (using Images)
Learn how to embed PDF invoices directly in HTML emails by converting the first page to an image. Since email clients don't support embedded PDFs, this technique uses the Apdf API to create visual invoice previews that increase engagement and trust with your customers.
Your code made the PDF.
Then it went dark.
Opened, read, re-read, dropped on page 4 — you never see any of it. Share the PDFs you generate through Apdf recipient links, and every signal becomes something you can act on: ping Slack, update the CRM, let an agent follow up. Same account, same API token, one more call.
API · Webhook · MCP