Convert your files with our online file conversion API

The ConvertAPI provides online API for creating PDF and Images from various sources like Word document, web pages or raw HTML codes. In just few minutes you can integrate it into your application and use it easily. Return to APIs list.

Do you have file format which is not supported by our ConvertApi online service? Just contact us and we will add it for you.

  1. Convert web page to Image API

    The API for converting web pages to Image files.

    Rest Api .Net Library

REST API Documentation

An API call is made by sending an HTTP request with parameters passed as POST data to the Web2Image service API URI:

Converted file is returned as HTTP response stream, additional data are available in HTTP response header. If API call is succeeded HTTP response status code will be 200 OK, if fail then 400 Bad Request.

Converted file and additional data are returned as JSon object. A file is encoded using Base64 encoding.

Below are properties supported by conversion api. The properties marked with "›" are write properties, they accepts values. The properties which has "‹" marker are read properties, they returns values.

ApiKey integer
API Key should be passed if you purchased membership with credits. Please login to your control panel to find out your API Key
Conversion Parameters
Timeout = 300 integer
Conversion timeout in seconds. The minimum value is 5 seconds and maximum is 600 seconds (10 minutes)
CUrl string
URI of a web page to convert. Must start with http:// or https://. Several URI of web pages merged with %20 (space) symbol can be passed to create one PDF. For example if URI will be passed the two web pages will be merged into one PDF. If URI has special characters like ? or & they must be encoded. Also a HTML code can be submitted for conversion using this parameter.
ConversionDelay = 0 integer
Delay in seconds before page load and PDF creation. Sometimes usefull to let web page to load in full.
AuthUsername string
HTTP authentication username, used if conversion web page is protected with HTTP authentication.
AuthPassword string
HTTP Authentication password, used if conversion web page is protected with HTTP authentication.
OutputFormat = jpg string (collention)
bmp - bmp image format
jpg - jpg image format
png - png image format
tiff - tiff image format
Set the output image format.
Credits Information
CreditsLeft integer
Return number of remaining credits. Only available when ApiKey is provided.
CreditsCost = 1 integer
The cost of credits for one conversion.
HTML Options
Scripts = true boolean
Allow web pages to run javascript.
Plugins = false boolean
Enable plugins such as flash.
HTTP Request Headers
UserAgent string
Set custom user agent.
AcceptLanguage string
Set accept language header.
Image Options
PageWidth = 1024 integer
Set screen width.
PageHeight = 0 integer
Set screen height. Default is calculated from page content.
Output Result
Result boolean
Conversion result. Return True if conversion successful, otherwise False.
Error string
Contain information about conversion failure. Only available when Result = False.
FileSize integer
Converted file size in bytes.
StoreFile = false boolean
Store file on server and return url to file instead of file stream response. File will be available for 24 hours.
FileUrl string
Converted file url to download from a server. Only available when StoreFile = True.
File bytes
If JSon object is used as output then a file will be encoded using Base64 encoding.
OutputFileName string
Converted output file name. If parameter is not set the filename will be generated automatically.