A new cache domain for screenshots

Cached screenshots and stored page content move to a new domain, screenshotonecache.com, to strengthen security.

Changelog1 min read

Written by

Dmytro Krasun

Published on

Why

Some of the files the API stores for you are HTML that comes from the pages you render, for example page content and screenshots in the html format. Serving them from a subdomain of screenshotone.com mixed content from any website with ScreenshotOne’s own domain.

Stored files now live on a separate domain, screenshotonecache.com, with a stricter security policy:

  • stored HTML is served with a sandboxing content security policy, so it never runs scripts and never submits forms;
  • browsers never guess a file’s type from its contents, so a file is always handled as the type it is stored with.

What changed

WhatBeforeNow
Cached screenshots: cache_url, screenshot_url and the X-ScreenshotOne-Cache-URL headercache.screenshotone.comfiles.screenshotonecache.com
Page content from metadata_contentcontent.screenshotone.comcontent.screenshotonecache.com

Only the host changes: the paths, the expiration and the way you request these files stay the same. The API no longer returns URLs on the old cache.screenshotone.com and content.screenshotone.com hosts.

What to check

Most integrations need no changes, because they use the URLs the API returns. Update your configuration if you allow hosts explicitly, for example:

  • an img-src or connect-src directive in your content security policy;
  • images.remotePatterns in Next.js;
  • a firewall or proxy allowlist.

Allow files.screenshotonecache.com and content.screenshotonecache.com there. If you build these URLs yourself instead of using the returned ones, switch to the new hosts.

Read more product updates

New features, bug fixes, and optimizations...

View all product updates
Improved proxy validation

Improved proxy validation

Stricter proxy option validation to prevent misconfiguration.

Read more

1 min read

I migrated to Google Cloud

I migrated to Google Cloud

Google Cloud gives $300 in credits for 3 months for experimenting. And I decided to give it a try, but not because of the free credits.

Read more

4 min read

New hover option

New hover option

Use the new hover option to interact with elements before rendering, and choose whether to fail if the hover selector is not found.

Read more

1 min read

Automate website screenshots

Exhaustive documentation, ready SDKs, no-code tools, and other automation to help you render website screenshots and outsource all the boring work related to that to us.