The Tool Desk
Outbyte PC Repair FREERepair Windows errors before they cause bigger problemsFix Now →Outbyte Driver Updater FREEScan for outdated or missing drivers - takes under a minuteDriver Scan →Set html2canvas’s proxy option to the URL of an endpoint that you operate. That endpoint must accept the requested resource in a ?url= query parameter and return the resource as a base64 data URI, as described in the html2canvas getting-started guide. The option does not create or host a proxy for you.
Use useCORS: true instead when the image server can send a suitable Access-Control-Allow-Origin response header. html2canvas documents useCORS as false by default and proxy as null by default (configuration reference).
What the html2canvas proxy option actually does
html2canvas reconstructs an image from the target element’s DOM and CSS; it does not capture the browser’s already-rendered pixels. Images that come from another origin can therefore fail because browser same-origin and content-policy rules prevent the library from reading them. The documentation explicitly says that proxying does not bypass those browser restrictions for every kind of content, and that cross-origin iframe contents cannot be read (documentation).
The proxy value is only a URL. When html2canvas needs an image, it can request your route with the image URL in a query parameter. Your server fetches that resource and responds in the format the library expects: a base64 data URI. You are responsible for authentication, validation, timeouts, caching, size limits and deployment.
#1 Best Overall
- 【WIRELESS MOBILE MINI TRAVEL ROUTER】 Convert a public network (wired or wireless) to a private Wi-Fi for secure surfing. Tethering. Powered by any laptop USB, power banks or 5V/2A DC adapters (sold separately). 39g (1.41 Oz) only, portable and pocket friendly. 2.4GHz ONLY
- 【OPEN SOURCE & PROGRAMMABLE】 OpenWrt pre-installed, USB disk extendable.
- 【LARGER STORAGE & EXTENDABILITY】 128MB RAM, 16MB Flash ROM, dual Ethernet ports, UART and GPIOs available for hardware DIY.
- 【OPENVPN CLIENT】 OpenVPN client pre-installed, compatible with 30+ VPN service providers.
- 【PACKAGE CONTENTS】 GL-MT300N-V2 (Mango) mini router (2-year Warranty), USB cable, Ethernet cable, User Manual. Please update to the latest firmware.
Choose CORS or a proxy
Use CORS when the image host is under your control
If the image server can return a response such as Access-Control-Allow-Origin for your page’s origin (or an appropriately restricted set of origins), configure html2canvas like this:
const canvas = await html2canvas(element, {
useCORS: true,
});
The image URL still has to load successfully, and the server’s CORS response must apply to the actual image request. A CORS setting in your page cannot manufacture a header on somebody else’s server.
Use a proxy when the image host cannot provide CORS
Point proxy at an endpoint you control:
const canvas = await html2canvas(element, {
proxy: '/proxy',
});
This is appropriate for a legacy asset host, a third-party service that will not change its headers, or an architecture where your backend is already allowed to retrieve the image. The route must be reachable by the browser and must implement the documented request and response contract.
Do not expect either setting to expose an iframe
A proxy can retrieve an image resource, but it cannot make the DOM inside a cross-origin iframe readable. The html2canvas documentation lists that iframe limitation as a browser security restriction. If the content you need is in an iframe, render an equivalent same-origin view or capture the iframe’s own page from a context that is permitted to read it.
Quick wins for a faster PC:
Clear out junk files and repair common Windows errorsFree Scan →Scan for outdated or missing drivers - takes under a minuteDriver Scan →Repair Windows errors before they cause bigger problemsFix Now →Implement a minimal proxy endpoint
The following Express example demonstrates the contract. It is intentionally a starting point rather than a production proxy: add access control, an allowlist of hosts, rate limiting, logging and stricter limits before exposing it publicly. Without those controls, an open fetch endpoint can be abused to access internal network addresses or consume your bandwidth.
Rank #2
- 【Advanced Home Data & Media Hub】For advanced home users who need phone backup, file storage, and centralized data management. Centralize family photos, 4K videos, movies, computer backups, and personal files in one place while running multiple apps for home entertainment and everyday data management. Suitable for households with growing digital libraries and multiple NAS use cases.
- 【Built for Creators, Media Servers & Advanced Apps】Powered by the Intel N100 Quad-Core CPU, 8GB DDR5 RAM, 2.5GbE networking, and dual M.2 NVMe slots, DXP2800 handles large files and heavier workloads with ease. Run Docker, virtual machines, and media server applications compatible with Plex—ideal for content creators, tech enthusiasts, and advanced home users managing 4K videos, RAW photos, personal media libraries, and multiple NAS apps.
- 【Up to 80TB for Growing Digital Libraries】 Supports up to 80TB of storage using two HDD bays and two M.2 NVMe SSD slots for family photos, movies, RAW photos, 4K videos, work files, and device backups. AI photo management supports recognition of people, objects, scenes, and locations, album organization, and duplicate photo detection. HDDs and SSDs are not included.
- 【AI-powered Home Surveillance】Turn DXP2800 into a centralized home surveillance hub by connecting compatible network cameras and storing recordings locally on your NAS. AI-powered features include Face Recognition, People Detection, and Pet Detection, helping advanced home users review important events more efficiently while managing home surveillance and personal data in one place.
- 【One data Center Across Your Devices】Keep files from desktops, laptops, phones, tablets, and other devices together instead of scattered across cloud accounts and external drives. Access, back up, organize, and share data across Windows, macOS, Android, iOS, web browsers, and compatible smart TVs—ideal for creators and advanced home users working across multiple devices.
Node.js example
import express from 'express';
const app = express();
const port = process.env.PORT || 3000;
app.get('/proxy', async (req, res) => {
const raw = req.query.url;
if (typeof raw !== 'string') {
return res.status(400).send('Missing url');
}
let target;
try {
target = new URL(raw);
} catch {
return res.status(400).send('Invalid url');
}
if (!['http:', 'https:'].includes(target.protocol)) {
return res.status(400).send('Only http and https are allowed');
}
const controller = new AbortController();
const timer = setTimeout(() => controller.abort(), 15000);
try {
const upstream = await fetch(target, { signal: controller.signal });
if (!upstream.ok) {
return res.status(502).send(`Upstream status ${upstream.status}`);
}
const contentType = upstream.headers.get('content-type') || '';
if (!contentType.startsWith('image/')) {
return res.status(415).send('Upstream response is not an image');
}
const bytes = Buffer.from(await upstream.arrayBuffer());
const dataUri = `data:${contentType};base64,${bytes.toString('base64')}`;
res.type('text/plain').send(dataUri);
} catch (error) {
res.status(504).send('Unable to retrieve image');
} finally {
clearTimeout(timer);
}
});
app.listen(port, () => console.log(`Proxy listening on ${port}`));
Install Express, run the server, and use the route from a page served by the same application:
npm install express
node server.js
Then configure the capture:
const canvas = await html2canvas(document.querySelector('#invoice'), {
proxy: '/proxy',
});
const png = canvas.toDataURL('image/png');
Some deployments return the data URI with a JSON envelope instead of plain text. That is only valid if it matches the response format expected by the html2canvas version you are using; follow the project’s proxy example rather than inventing a different schema.
Production safeguards
- Allowlist destinations. Permit only the image domains your application needs. Block loopback, private, link-local and cloud metadata addresses after DNS resolution.
- Limit size and duration. Reject unexpectedly large content, enforce a short timeout and avoid buffering unlimited responses in memory.
- Restrict methods and content. Accept only GET, require an image content type and do not forward arbitrary request headers from visitors.
- Authenticate the route. A private application route should require the same session or token as the page that calls it.
- Cache carefully. Cache by normalized URL and content variant, with an explicit expiration. Do not cache personalized or authorization-protected images for other users.
- Observe failures. Log upstream status, response size and elapsed time without recording secrets embedded in URLs.
Complete browser configuration patterns
CORS-enabled images
async function renderWithCors() {
const element = document.querySelector('#report');
return html2canvas(element, {
useCORS: true,
backgroundColor: '#ffffff',
});
}
The extra option in this example only sets the canvas background; the cross-origin behavior comes from useCORS: true and the image server’s response headers.
Do these 3 things before closing this tab:
1Scan for outdated or missing drivers - takes under a minute2Clear out junk files and repair common Windows errors3Fix the driver behind crashes, sound loss and screen glitchesImages through your proxy
async function renderWithProxy() {
const element = document.querySelector('#report');
return html2canvas(element, {
proxy: '/proxy',
});
}
If your proxy is hosted on another origin, use its complete HTTPS URL and configure that server for the browser request. A relative URL is usually simpler because it follows the page’s origin.
Choosing per environment
Development may use useCORS against a local asset server, while production uses a controlled proxy for domains that cannot change their headers. Keep the choice explicit in configuration so a deployment does not silently point at an unavailable development route.
Rank #3
- One Place for All Your Data - Consolidate scattered files from multiple computers, phones and external drives into one accessible hub with 100% ownership
- Professional File Collaboration - Share projects with clients, sync documents across teams and maintain version control without Dropbox fees
- Automated Backup Protection - Set-and-forget backups for Macs, PCs and mobile devices to multiple destinations including cloud and external drives
- DIY Surveillance System - Transform IP cameras into a professional monitoring solution with motion alerts, recording schedules and remote viewing
- 2-Year Warranty - Reliable hardware backed by Synology's expert customer support team and ongoing software updates
Why images still do not appear
The proxy route is never requested
Open browser developer tools and inspect the Network panel while calling html2canvas. If there is no request to the configured route, check that the option is spelled proxy, that the value is a URL string, and that the code path actually captures the intended element.
The route returns HTML, JSON or an error page
Request the route directly with an encoded URL. The response should be the base64 data URI required by the getting-started guide, not your application’s login page, a framework error document or an upstream HTML page. Verify the status code, content type and response body before debugging html2canvas.
Free tools Windows power users keep installed
One-click scans. No signup required.
The upstream server blocks your backend
Some hosts reject unknown user agents, require authentication or disallow server-side requests. The proxy cannot retrieve a resource that its own network is not permitted to fetch. Use an authorized asset endpoint, change the upstream policy, or keep the asset on a host you control.
CORS headers are missing or too broad
When using useCORS, inspect the image response itself. The header must be present on the image request, not only on an HTML document or an unrelated API response. If you cannot make the header correct, switch to a properly secured proxy.
Mixed content blocks the request
A page loaded over HTTPS should not depend on an HTTP proxy or image URL. Serve the proxy over HTTPS and use HTTPS upstream URLs where available.
Rank #4
- Unlimited bandwidth, unlimited data.
- Super-fast VPN and one tap connect.
- Free worldwide multiple servers.
- Works with all type of data carries. (Wi-Fi, 4G, LTE, 3G).
- No registration, sign up needed.
The image loads but the canvas is unusable
Check the browser console for a tainted-canvas or security error and confirm that every image in the target subtree follows the same-origin or CORS/proxy path. One unhandled cross-origin image can affect the resulting canvas.
The target is a cross-origin iframe
This is not a proxy-configuration bug. html2canvas cannot read the iframe’s document under browser security rules (FAQ). Capture content that your page can legally access instead.
Independent reader supportYour contribution helps us test, update, and keep practical guides available for everyone.Performance, reliability and visual accuracy
Request cost and latency
A proxy adds a browser-to-server request and a server-to-upstream request, then transfers a base64 representation back to the browser. Large images therefore consume more memory and bandwidth than their binary form. Resize source assets where possible, avoid loading images that are hidden from the capture, and cache stable public assets.
Failures and retries
Handle upstream timeouts and non-2xx responses as capture failures, not as valid image data. If you retry, use a small bounded retry policy; repeated retries can multiply load when an upstream host is down. Return a clear error status so the browser can distinguish an unavailable asset from an empty image.
Output differences
Because html2canvas reconstructs from DOM and style information, fonts, animations, pseudo-elements and browser-specific layout can differ from what a user sees. Freeze animations, wait until images and fonts are ready, and compare output in the browsers you support. A proxy fixes resource access; it does not turn html2canvas into a literal screenshot API.
Best Value
- Complete Phone & Computer Backup - Automatically protect photos, documents and videos from iPhone android, Mac and Windows to one secure location
- Your Private File Cloud - Access files from anywhere and share large projects with family or clients without relying on expensive cloud subscriptions
- Smart Home Security Hub - Monitor your home 24/7 with AI-powered surveillance that detects people, vehicles and sends instant alerts
- 100% Data Ownership - Keep full control of your personal data with multi-platform access and no monthly subscription fees
- 2-Year Warranty - Reliable hardware backed by Synology's expert customer support team and ongoing software updates
Or skip the browser setup
For a server-side screenshot rather than a DOM reconstruction, ScreenshotNeo provides a website screenshot API and MCP server. One request returns PNG, JPEG, WebP or PDF. It accepts cookie and consent banners before capture and removes more than 60 known consent platforms, newsletter popups and chat widgets; bot checks, blank pages, timeouts, failed loads and cache hits are not billed, and response headers identify the page verdict and billing result. AI agents can call its take_screenshot, get_page_info and capture_pdf MCP tools.
One-call cURL example (see the ScreenshotNeo documentation):
curl -G "https://api.screenshotneo.com/v1/shot" -d access_key=YOUR_API_KEY --data-urlencode url=https://stripe.com -o shot.webp
Python:
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)
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}`);
Every plan includes the features; the Free plan provides 1,000 screenshots per month with no card, and paid plans start at $5 for 3,000 shots. Create a free ScreenshotNeo account to try it without a card.
FAQ
Does setting proxy install a proxy service?
No. It only tells html2canvas where your own endpoint is. You must implement and secure that endpoint.
What’s actually slowing this PC down?
Pick the symptom - the matching free tool is one click away.
What should the proxy return?
The documented contract uses a ?url= request parameter and a base64 data URI response. Match the format shown in the project’s getting-started documentation.
Can a proxy bypass all browser security rules?
No. It can help with image retrieval, but cross-origin iframe documents remain inaccessible to html2canvas.

