How to convert a website screenshot to PDF with Cloudinary
Capture a public webpage with Cloudinary’s URL2PNG add-on, then deliver the screenshot as a PDF or combine multiple screenshots into one file.
To convert a website screenshot to PDF with Cloudinary, first use its URL2PNG add-on to capture a public webpage as an image, then deliver that screenshot in PDF format. For one screenshot, Cloudinary documents changing the delivery URL extension to .pdf or setting the format to pdf. For multiple screenshots in one multi-page PDF, use Cloudinary’s multi method.
This is a two-step image workflow, not a documented direct webpage-to-PDF capture endpoint. URL2PNG’s listing describes public webpage screenshots; the sources here do not establish support for login-protected pages. See Cloudinary’s URL2PNG add-on listing and PDF creation guide.
1. Capture the public webpage with URL2PNG
- Check in the Cloudinary Console whether the URL2PNG Website Screenshots add-on is available for your account.
- Use the add-on’s documented flow to submit the public webpage URL and obtain a screenshot image. The add-on listing describes screenshot capture and image transformation delivery.
- Keep the resulting screenshot image available as a Cloudinary asset so you can request it in PDF format in the next step.
The add-on listing includes a dynamic delivery URL example, but its exact URL construction and account-specific availability should be taken from the listing and your Console. Do not treat URL2PNG as a general webpage-to-PDF endpoint: the documented sequence here is webpage to image, followed by image to PDF.
2. Deliver one screenshot as a PDF
Cloudinary supports delivering a PDF from a single image as an on-the-fly transformation. Change the delivery URL’s file extension to .pdf, or set the output format to pdf, while retaining any image transformations you need. Cloudinary’s Transformation URL API reference covers URL syntax, which can vary by SDK.
Conceptually, use the Cloudinary delivery URL for your screenshot asset and request its PDF format. The exact URL depends on the delivery type, public ID, and transformations in your account; use the URL2PNG-generated delivery URL as the starting point rather than assuming a universal URL template.
https://res.cloudinary.com/<cloud_name>/<delivery_type>/<transformations>/<public_id>.pdf
Alternatively, use the format parameter in the delivery URL or your SDK’s equivalent to request PDF output. If the URL is rejected or the response is not a PDF, check the asset’s delivery permissions and the URL transformation syntax.
3. Combine multiple screenshots into one PDF
For a multi-page PDF, upload the screenshot images to Cloudinary and use the Upload API’s multi method. Cloudinary documents a maximum of 100 images for a synchronous request and 500 images for an asynchronous request. These are per-request limits, not plan allowances.
- Page order: when selecting assets with the same tag, pages are ordered by public ID alphabetically. Name IDs with sortable prefixes such as
01,02, and03to control the sequence. - Request size: keep each request within its sync or async image limit. Split larger collections into separate operations.
- Output: use the PDF creation workflow documented for
multi, and retrieve the resulting PDF from Cloudinary.
Refer to Cloudinary’s multi-image PDF instructions for the current API parameters and SDK syntax. This article does not invent a request body because the documented syntax depends on the API or SDK call you choose.
4. Check PDF delivery settings
If Cloudinary produces the PDF but will not deliver it, inspect the account’s Security settings. Cloudinary says PDF and ZIP delivery may be blocked by default on free accounts. Check whether Allow delivery of PDF and ZIP files is enabled. See the PDF handling guide.
Choose the right workflow
| Need | Cloudinary workflow | Detail to account for |
|---|---|---|
| One public webpage screenshot as a PDF | URL2PNG screenshot, then single-image PDF delivery | Request the asset with a .pdf extension or PDF format. |
| Several screenshots in one PDF | Upload images, then use the multi method |
Up to 100 images synchronously or 500 asynchronously; alphabetical public ID order applies when selecting by a shared tag. |
| Word, Excel, or PowerPoint document to PDF | Separate document-conversion use case | Cloudinary’s PDF handling guide mentions its Aspose document conversion add-on. This is not the webpage screenshot flow. |
Common problems and fixes
| Symptom | Likely cause | What to check |
|---|---|---|
| PDF URL is blocked or access is denied | PDF/ZIP delivery permission is disabled; this may be the default on a free account. | Review Security settings and the “Allow delivery of PDF and ZIP files” setting. |
| The result is still an image | The delivery URL did not request PDF output. | Change the extension to .pdf or set the format to pdf; confirm the transformation URL follows the syntax for your SDK. |
| A page in a multi-image PDF is out of order | Assets selected by a shared tag are ordered by public ID alphabetically. | Use sortable public IDs such as 01-cover, 02-details, and 03-summary. |
| A multi-image request exceeds its limit | The request includes more images than its execution mode allows. | Use no more than 100 images for a synchronous request or 500 for an asynchronous request, or split the work. |
| The page cannot be captured | The documented URL2PNG scope is public webpages; private or login-protected page support is not established by the cited listing. | Confirm the page is publicly accessible. Do not assume the add-on can use an authenticated browser session. |
| The expected add-on is unavailable | Availability can depend on the account. | Check the URL2PNG listing in the Cloudinary Console for your account. |
Performance, reliability, and cost considerations
- Capture and conversion are separate operations. The webpage must first be captured as an image; the PDF is then delivered from that image. Plan for both stages in your application flow.
- Multi-image requests have explicit limits. Use asynchronous processing when appropriate for larger collections, while staying within the documented 500-image maximum; synchronous requests allow up to 100.
- Page order depends on asset naming. Alphabetical public ID ordering is predictable when IDs use zero-padded sequence prefixes.
- Availability and pricing need account-level verification. The URL2PNG add-on listing shows plan figures, but billing period, currency treatment, regional availability, and current purchasability for a particular account are not established here. Check the current Console listing before budgeting.
- Delivery permissions can affect reliability. Verify PDF delivery security settings before wiring a PDF URL into a production workflow.
Or skip the browser setup
If your goal is a PDF of a webpage and you do not need to build the capture step yourself, ScreenshotNeo is a website screenshot API and MCP server. It returns a PDF from one GET request. See the ScreenshotNeo API documentation.
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -d format=pdf -o page.pdf
Cookie banners, popups, and chat widgets are removed before the shot. Bot checks, blank pages, and failed loads are never billed. An MCP server lets AI agents take screenshots. The free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000 shots.
Create a free ScreenshotNeo account to get 1,000 screenshots a month with no card.
FAQ
Does URL2PNG directly convert a webpage into a PDF?
The documented workflow is to capture a public webpage as an image, then deliver that image as a PDF. The add-on listing describes screenshot capture, while the PDF guide describes image-to-PDF delivery.
Can I make one PDF from multiple webpage screenshots?
Yes. Capture and upload the images, then use Cloudinary’s multi method. Observe the 100-image synchronous and 500-image asynchronous limits.
Why might a PDF work for one account but not another?
Cloudinary documents that PDF and ZIP delivery may be blocked by default on free accounts. Review the account’s Security settings.
Does the same method convert Office documents?
That is a different workflow. Cloudinary’s PDF handling guide mentions an Aspose add-on for Office document conversion; URL2PNG is for webpage screenshots.


