URL-to-PNG provides a single endpoint that accepts various query parameters to customize the generated image.
url
(required): The valid URL to be captured.width
(optional): The width of the output screenshot. Default is 250
.height
(optional): The height of the output screenshot. Default is 250
.viewPortWidth
(optional): The width of the render viewport. Default is 1080
.viewPortHeight
(optional): The height of the render viewport. Default is 1080
.forceReload
(optional): Forces a reload of the cached image. Default is false
.isMobile
(optional): Adds a mobile flag to the user agent. Default is false
.isFullPage
(optional): Renders the full page instead of the viewport crop. Default is false
.isDarkMode
(optional): Prefers the dark color scheme. Default is false
.deviceScaleFactor
(optional): Specifies the device scale factor (can be thought of as DPR). Default is 1
.Here are some example combinations of query parameters:
https://url2png.lp2.me?url=https://lp2.meUse in your HTML
<img src="https://url2png.lp2.me?url=https://lp2.me" alt="lp2.me web page screenshot">