Monitor changes to website scripts

See when JavaScript changes on your Cloudflare-proxied site. Script Guard saves script versions so you can compare them and alerts you when it finds suspicious code.

checkout.js

shop.example · Script version history

Previous capture · v44
Clear
Latest capture · v45
Suspicious
New in v45
Code sends checkout form data to an unexpected domain
View example security report

Script Guard found an outbound request containing checkout form data in the saved v45 code. The request was absent in v44.

How it works

  1. Enable monitoring

    Use MCP to enable Script Guard on a site already connected to Cloudflare.

  2. Receive script alerts

    Send script alerts to your agent by webhook with the version and report link.

  3. Review the change

    Have your agent summarize the alert and flag which script version to review.

What you get

Compare saved versions of checkout, analytics, and chat scripts. The checkout report shows what the script started sending and gives the team evidence for its incident review.

Script version reportExample output
experiment.js v14 · Markdown report excerpt
## Changes- The previous version sent only the experiment variant.## Findings### Checkout data in a vendor eventThe captured source now includes a checkout form value in the event sent to the experiment provider.
Suspicious

The checkout team disables the vendor script and exports the report for the incident review.

Use cases

  • Keep track of third-party JavaScript

    Follow changes to scripts from analytics, chat, and experimentation tools that can update independently of your site.

  • Investigate unexpected script behavior

    Compare saved versions and export a Markdown report with the relevant code for your incident review.

Frequently asked questions

Monitor your website scripts

Connect Cloudflare and enable Script Guard for the sites you want to monitor.

Get started