WPD to PNG API
Send a WordPerfect file to POST /v2/convert/wpd/to/png and get a PNG of every page. With no options, the two-page sample returns 262,729 and 186,058 bytes of RGB pixels drawn at 150 DPI, with no alpha channel.
- Endpoint
- POST /v2/
convert/ wpd/ to/ png - Accepts
- wpd
- Sample timing
- 0.572 s median of 5 runsHow we measure
- Request size
- Up to 10 MB on the Free plan or 100 MB on paid plans, all files together
Request and response
Every sample below ran against the API before this page was published. Set PDFCONVERSIONAPI_KEY to your key and run it as is.
curl -sS -X POST \
https://api.pdfconversionapi.com/v2/convert/wpd/to/png \
-H "Authorization: Bearer $PDFCONVERSIONAPI_KEY" \
-F File=@hearing-notice.wpd \
-o response.json
# FileData is base64. Save the first file in converted/,
# or print the JSON error.
if jq -e '.Files' response.json > /dev/null; then
mkdir -p converted
name=$(jq -r '.Files[0].FileName' response.json)
jq -r '.Files[0].FileData' response.json \
| base64 --decode > "converted/$name"
else
cat response.json
fiimport base64
import os
import requests
key = os.environ["PDFCONVERSIONAPI_KEY"]
response = requests.post(
"https://api.pdfconversionapi.com/v2/convert/wpd/to/png",
headers={"Authorization": f"Bearer {key}"},
files=[("File", open("hearing-notice.wpd", "rb"))],
timeout=180,
)
result = response.json()
if not response.ok:
raise SystemExit(f"{result['Code']}: {result['Message']}")
os.makedirs("converted", exist_ok=True)
for file in result["Files"]:
path = os.path.join("converted", file["FileName"])
with open(path, "wb") as out:
out.write(base64.b64decode(file["FileData"]))
print(path, file["FileSize"], "bytes")
import { mkdir, readFile, writeFile } from "node:fs/promises";
import { join } from "node:path";
const form = new FormData();
const file = "hearing-notice.wpd";
form.append("File", new Blob([await readFile(file)]), file);
const url = "https://api.pdfconversionapi.com/v2/convert/wpd/to/png";
const key = process.env.PDFCONVERSIONAPI_KEY;
const response = await fetch(url, {
method: "POST",
headers: { Authorization: `Bearer ${key}` },
body: form,
});
const result = await response.json();
if (!response.ok) {
throw new Error(`${result.Code}: ${result.Message}`);
}
await mkdir("converted", { recursive: true });
for (const file of result.Files) {
const path = join("converted", file.FileName);
await writeFile(path, Buffer.from(file.FileData, "base64"));
console.log(path, file.FileSize, "bytes");
}
{
"ConversionCost": 1,
"ConversionTime": 0.572,
"Files": [
{
"FileName": "hearing-notice-1.png",
"FileExt": "png",
"FileSize": 262729,
"FileData": "iVBORw0KGgoAAAANSUhEUgAA…"
},
{
"FileName": "hearing-notice-2.png",
"FileExt": "png",
"FileSize": 186058,
"FileData": "iVBORw0KGgoAAAANSUhEUgAA…"
}
]
}Response from our test run on 2026-11-03. ConversionTime shows the median of 5 runs. FileData is shortened here; the real response carries the whole file as base64.
The sample, converted
The same file the code sends. Download the input and the output and compare them yourself.

- Input
- hearing-notice.wpd (1.8 KB)
- Output
- hearing-notice-1.png (257 KB)hearing-notice-2.png (182 KB)
- Source
- A two-page WordPerfect 5.1 public hearing notice for a fictional township, which we wrote byte by byte from the file format description (CC0-1.0). How it was made
- Made by
- 2026-11-04, API build
9eeeb0640aba
Parameters
Send these as form fields next to the file. Names are case-insensitive. If you set one of the documented options below that we don't support yet, the request fails with a 400 that names it instead of returning a file made without it.
| Parameter | What it does |
|---|---|
ImageResolutioninteger, default 150 | Pixels per inch of paper, stored in the PNG's pHYs chunk when you send it. 72 gives 612 × 792 (100,638 bytes for page 1); 300 gives 2,550 × 3,300.Values: 36 to 600 |
ColorSpaceenum, default default | gray keeps one channel instead of three and stored page 1 in 98,337 bytes. monochrome leaves only the values 0 and 255: 32,994 bytes. rgb gives the same 262,729-byte file as the default, which is already three-channel RGB.Values: default, rgb, gray, monochrome |
TransparentColorstring | One exact color to clear. white made 96.6% of page 1 transparent, so only the type and the strikeout and underline rules stay.Values: Color name, #RRGGBB or R,G,B |
BackgroundColorstring | Color of the paper behind the text, white when left out.Values: Color name, #RRGGBB or R,G,B |
PageRangestring | Which pages to draw; 2 returns the hearing procedure page alone.Values: Page numbers and ranges |
ImageWidthinteger | Output width in pixels; the page is drawn at the scale that width needs.Values: 1 to 20,000 |
ImageHeightinteger | Output height in pixels: 600 gave 464 × 600. With ImageWidth=400 as well, the page fits the box at 309 × 400.Values: 1 to 20,000 |
ScaleProportionsboolean, default true | false stretches the page to exactly ImageWidth × ImageHeight: 400 × 400 for a 400-pixel box. |
ScaleImageboolean, default true | false cuts instead of scaling: ImageWidth=600 with ImageHeight=300 returned the top-left 600 × 300 pixels of the page drawn at 150 DPI. |
FileNamestring | Stem for -1.png, -2.png and so on. |
StoreFileboolean, default false | Store the PNGs and send back links that expire after 3 hours. |
What carries over, and what doesn't
Kept
- Exact pixels: PNG is lossless, so even the 7.2 pt disclaimer has no compression artifacts around its letters
- The page's tonal range: 256 shades of neutral gray and no color, as the document is black on white
- Each paragraph's alignment from the WordPerfect codes: the justified block, the centered heading and the right-aligned posting date
- Page order, as
hearing-notice-1.pngandhearing-notice-2.png
Lost or not yet supported
- A see-through background unless you ask: the default PNG has no alpha channel, and only
TransparentColoradds one. - Copyable text. Use the PDF route to keep the words.
- The document's font: text set in the WordPerfect default, Times New Roman, is drawn in Liberation Serif.
- A DPI value when
ImageResolutionis left out.
Limits
ImageWidthandImageHeighttake up to 20,000, but a Letter page 9,000 pixels wide is 104.8 million pixels and returns 413; the cap is 100 million pixels and 16,000 pixels per side.PageSize,PageOrientationand other page setup options return 400 "... is not supported yet for WPD files".- Up to 2,000 pages, 10 MB on the Free plan or 100 MB on paid plans per request and 120 seconds per conversion; a longer run returns 504.
Where teams use it
Page images for a document viewer
A viewer built on plain image tags can show .wpd files once each page is a PNG. Lossless pixels keep thin rules such as the notice's strikeout and underline free of compression noise.
Overlays and compositing
With TransparentColor=white the paper disappears and the text can be laid over a letterhead, a form background or a slide.
Questions
How do I get a PNG with a transparent background?
Send TransparentColor=white. The paper becomes transparent and the text stays: 2,032,283 of page 1's 2,103,750 pixels were cleared. The light gray pixels along the edges of letters are not pure white, so they stay opaque.
How can I make the PNGs smaller?
For pages of text, ColorSpace=gray keeps every shade and cut page 1 from 262,729 to 98,337 bytes. monochrome drops the smoothing for 32,994 bytes, and a lower ImageResolution cuts the pixel count further.
What resolution do I need for small print?
The notice's 7.2 pt line is drawn at 15 pixels per em at the default 150 DPI. For printing or close reading, ImageResolution=300 draws page 2 at 2,550 × 3,300 pixels in 452,335 bytes.
Convert your first WPD file in a minute.