ScreenshotNeo

BlogHow-to

How to Capture a Full-Page Website Screenshot with CloudConvert

Create a CloudConvert capture-website job, export a full-height PNG or JPG, and handle readiness, asynchronous jobs, and common errors.

By the ScreenshotNeo team4 October 20268 min read

To capture a full-page website screenshot with CloudConvert, create an API v2 job with a capture-website task, set its url and image output_format to png or jpg, then add an export/url task that takes the capture task as input. CloudConvert says full-height screenshots are captured by default. This is an API workflow, not a browser-menu command.

The examples below show the job shape. They use a placeholder for the API key and have not been run. Check CloudConvert’s current operation documentation for available capture options and formats, since supported options vary by output format. Capture Website operation documentation.

1. Create a CloudConvert API key

Create or use a CloudConvert account and obtain an API key with permission to create and manage jobs. Keep the key on your server or in a secret manager; do not put it in browser-side JavaScript, a public repository, or a URL you share.

CloudConvert organizes API v2 work as jobs containing tasks. The API documentation lists the standard API endpoint and region-specific endpoints. Use the endpoint configured for your account and region rather than assuming one geography is right for every account. See the CloudConvert API documentation.

2. Build the capture and export job

Use a target page that the CloudConvert browser can reach. Set the capture task’s operation to capture-website, provide the page URL, and select png or jpg. Then export the resulting file by referring to the capture task’s name in the export task’s input.

{
  "tasks": {
    "capture_page": {
      "operation": "capture-website",
      "url": "https://example.com/",
      "output_format": "png"
    },
    "export_capture": {
      "operation": "export/url",
      "input": "capture_page"
    }
  }
}

Replace https://example.com/ with the page you want to capture. The names capture_page and export_capture are labels for the tasks; keep the export task’s input equal to the capture task’s name. Submit the job using the documented API v2 jobs endpoint and authenticate with your API key as described in CloudConvert’s API documentation. The response or later job status provides the export result; retrieve the exported file URL and download it before it expires according to the service’s current behavior.

CloudConvert also documents supplying an HTML file as the capture input. Use that when the source is an HTML artifact rather than a publicly reachable URL, and follow the current operation documentation for the import task and its connection to the capture task.

3. Choose an output and configure readiness

Choice Use it when
png Your downstream workflow expects a PNG image.
jpg Your downstream workflow expects a JPG image.
pdf You need a document output rather than a single screenshot image; PDF is also documented for this operation.

For a page that renders content after navigation, CloudConvert’s product page describes waiting for a CSS selector to appear. Pick a selector that only becomes available when the content you need is ready. Do not add a selector wait if the page does not need it. For protected resources, CloudConvert documents custom authorization headers; provide only the headers required to access the page, and verify their supported format in the current docs.

Full-height capture is the stated default. If you need a custom viewport, zoom, resizing behavior, dimensions, or timing controls, consult the current capture operation documentation: the applicable options can depend on output format and may change.

4. Handle job completion

CloudConvert describes both asynchronous jobs and synchronous processing. An asynchronous job suits a background worker or queue: submit the job, wait for its completion through the documented job status or notification mechanism, then fetch the exported result. Synchronous processing is useful when the caller needs to wait for a result in the same request and the operation fits its request-time limits.

For production systems, avoid holding a web request open indefinitely. Track the job identifier, apply a bounded wait or use the documented asynchronous flow, and report a useful pending or failed state to your caller. Keep the export URL only as long as needed to download and store the output.

5. Runnable request examples

The following cURL example submits the job to the API v2 jobs endpoint. Set the API key in the environment first. The body is the same capture-plus-export job shown above.

export CLOUDCONVERT_API_KEY='YOUR_API_KEY'
curl --request POST 'https://api.cloudconvert.com/v2/jobs' \
  --header "Authorization: Bearer $CLOUDCONVERT_API_KEY" \
  --header 'Content-Type: application/json' \
  --data '{
    "tasks": {
      "capture_page": {
        "operation": "capture-website",
        "url": "https://example.com/",
        "output_format": "png"
      },
      "export_capture": {
        "operation": "export/url",
        "input": "capture_page"
      }
    }
  }'

This submits a job; it does not itself download the output. Inspect the returned job and task data, wait for completion if needed, then use the export task’s result URL to download the image. Consult the API docs for current response fields and job retrieval behavior.

CloudConvert’s API v2 documentation lists official SDKs for PHP, Node.js, Python, Ruby, Java, and .NET. The direct HTTP examples below make the job submission shape explicit. They require Python’s requests package or a modern Node.js runtime with fetch.

Python

import os
import requests

api_key = os.environ["CLOUDCONVERT_API_KEY"]
payload = {
    "tasks": {
        "capture_page": {
            "operation": "capture-website",
            "url": "https://example.com/",
            "output_format": "png",
        },
        "export_capture": {
            "operation": "export/url",
            "input": "capture_page",
        },
    }
}

response = requests.post(
    "https://api.cloudconvert.com/v2/jobs",
    headers={"Authorization": f"Bearer {api_key}"},
    json=payload,
    timeout=30,
)
response.raise_for_status()
print(response.json())

Node.js

const apiKey = process.env.CLOUDCONVERT_API_KEY;
if (!apiKey) throw new Error("Set CLOUDCONVERT_API_KEY first");

const payload = {
  tasks: {
    capture_page: {
      operation: "capture-website",
      url: "https://example.com/",
      output_format: "png"
    },
    export_capture: {
      operation: "export/url",
      input: "capture_page"
    }
  }
};

const response = await fetch("https://api.cloudconvert.com/v2/jobs", {
  method: "POST",
  headers: {
    Authorization: `Bearer ${apiKey}`,
    "Content-Type": "application/json"
  },
  body: JSON.stringify(payload)
});
if (!response.ok) {
  throw new Error(`CloudConvert returned ${response.status}: ${await response.text()}`);
}
console.log(await response.json());

These examples submit the job and print its response; they do not assume response fields or fabricate a download URL. Use the current API docs to inspect the returned job, retrieve its status as needed, and download the export task’s result.

6. Troubleshooting

Symptom Likely cause What to check
Authentication or permission error The key is missing, invalid, or lacks the needed permissions. Confirm the bearer token is set on the server, use the correct account and API endpoint, and check the key’s permissions.
Job or task reports an error A task name, operation, input reference, URL, or output format is invalid. Verify capture-website, use png or jpg for the image examples, and ensure the export task input exactly matches the capture task name.
Capture is missing late page content The page had not rendered the desired content before capture. Use a CSS selector wait for a stable element that indicates the content is ready, and confirm that the element exists on the page in the capture environment.
Protected page cannot be captured The remote page requires authentication or access headers. Use the documented custom authorization headers if appropriate, and verify that the page permits access from the capture service.
Only a viewport-sized result appears The requested output or options may differ from the expected screenshot behavior. Check that the operation and output format are correct, and consult the current docs for full-height defaults and any viewport or resizing options.
Job submission succeeds but no file is saved Job creation and output download are separate steps. Wait for the job and export task to complete, obtain the export result URL from the current response format, and download the file.
Client times out while the job is still processing The client is waiting synchronously for work that takes longer than its timeout. Use asynchronous job handling or increase a bounded client timeout where appropriate; do not assume a submission response means the capture is finished.

7. Performance, reliability, and cost considerations

  • Processing time: A full-height capture has to render the target page and its content. Page complexity and readiness requirements affect how long a job takes; no fixed duration is guaranteed here.
  • Reliability: Treat the workflow as a job lifecycle. Record job and task status, handle errors, and only expose a completed export to downstream consumers. Use asynchronous completion for workflows that should survive caller disconnects.
  • Secrets: Keep API keys server-side and avoid logging authorization headers. Treat authorization headers and export URLs as sensitive.
  • Cost: API usage is subject to CloudConvert’s current account pricing and job terms. The cited research does not establish a current price for this operation; check CloudConvert’s current pricing before estimating spend.
  • Format: Choose PNG or JPG to match the next system’s requirements. Use PDF when the required artifact is a document, not an image.

Or skip the browser setup

ScreenshotNeo is a website screenshot API and MCP server. Its one-call API can return a PNG, JPEG, WebP, or PDF. Cookie banners are accepted and removed before the shot, and known newsletter popups and chat widgets are removed. Bot checks, blank pages, failed loads, timeouts, and cache hits are not billed; response headers report the page verdict and billing status. Its MCP server lets AI agents use take_screenshot, get_page_info, and capture_pdf. The free plan includes 1,000 screenshots a month with no card; paid plans start at $5 for 3,000.

Install Python’s requests package to run the Python example. Replace the target URL and API key, then save the returned image bytes:

import requests
r = requests.get("https://api.screenshotneo.com/v1/shot", params={"access_key": "YOUR_API_KEY", "url": "https://stripe.com"}, timeout=90)
open("shot.webp", "wb").write(r.content)

Or use cURL:

curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp

Or use Node.js:

const q = new URLSearchParams({ access_key: 'YOUR_API_KEY', url: 'https://stripe.com' });
const res = await fetch(`https://api.screenshotneo.com/v1/shot?${q}`);

See the ScreenshotNeo API documentation for the available options and setup details. Sign up for ScreenshotNeo to get 1,000 screenshots a month free with no card.

FAQ

Does CloudConvert capture the whole page by default?

Its website screenshot product page says full-height screenshots are captured by default. Check the current operation docs if you are setting custom viewport or resizing options.

Can I capture a page that is not public?

CloudConvert documents custom authorization headers for protected resources. Whether a particular page can be captured depends on its access controls and the current operation options.

Can I get a PDF instead of an image?

Yes. The operation documentation includes PDF output. Treat it as a document output; PNG and JPG are the image formats described for screenshots.

Is an Amazon product required?

No. This workflow uses CloudConvert’s digital service and API; it does not require a physical product.

Sources