Image to PDF
Wrap a remote image inside a PDF file.
GET
10 credits
/v1/convert/image-to-pdf
curl -OJ "https://convert.toolkitapi.io/v1/convert/image-to-pdf?url=https://toolkitapi.io/photo.jpg"
import httpx
resp = httpx.get(
"https://convert.toolkitapi.io/v1/convert/image-to-pdf?url=https://toolkitapi.io/photo.jpg",
)
print(resp.json())
const resp = await fetch("https://convert.toolkitapi.io/v1/convert/image-to-pdf?url=https://toolkitapi.io/photo.jpg", {
});
const data = await resp.json();
console.log(data);
# See curl example
Response
200 OK
Binary PDF file streamed as a download (Content-Type: application/pdf)
Description
Wrap a remote image inside a PDF file.
How to Use
1
1. GET this endpoint with the image `url`.
2
2. Optionally set `page_size`.
3
3. Save the streamed PDF.
About This Tool
Wraps an image inside a PDF at the image's native aspect ratio. Useful when a workflow only accepts PDFs — form submissions, document-management systems, and print services.
Any image format supported by the service can be used as input: PNG, JPEG, WebP, HEIC, TIFF, BMP, GIF.
Why Use This Tool
- Form submissions — Upload a photo where only PDF is accepted
- Print — Send photos to PDF-only print queues
- Document bundling — Prepare images for inclusion in a PDF-centric workflow
- Accessibility — Embed images in PDF for assistive-tech pipelines
Frequently Asked Questions
Is the image scaled?
Yes — the image is fitted inside the page with reasonable margins, preserving aspect ratio.
Can I combine multiple images into a single PDF?
Not via this endpoint. Use the document converter with HTML source referencing multiple images.
Is EXIF embedded?
No — the PDF contains the rasterized image only. Orientation is applied visually before embedding.
Start using Image to PDF now
Get your free API key and make your first request in under a minute.