Skip to content

IndexNow: tell search engines which pages changed after each deploy - #31

Merged
dpdev69 merged 1 commit into
mainfrom
claude/indexnow-ping
Nov 19, 2026
Merged

dpdev69 merged 1 commit into
mainfrom
claude/indexnow-ping

Conversation

@dpdev69

@dpdev69 dpdev69 commented Nov 19, 2026

Copy link
Copy Markdown
Owner

Requested by Boss · project thread

Adds an IndexNow ping so Bing, Yandex and other IndexNow search engines hear about changed pages right after a deploy. (Google does not use IndexNow; it reads sitemap.xml.)

  • tools/indexnow.mjs: no dependencies, Node 20+. Reads the sitemap, picks the pages whose HTML changed since a commit (or all of them), checks the key file is live, then posts the list to api.indexnow.org.
  • .github/workflows/indexnow.yml: runs on a push to main that changes a page (site/**.html) or site/sitemap.xml. It waits two minutes for Cloudflare Pages to publish, then sends only the changed pages. No secrets, no third-party actions.
  • The public key file at the root of the published directory (site/). The key is public by design.

A failed ping never fails anything: network errors, a non-2xx answer or a key file that is not live yet only log a warning, and the script exits 0.

By hand: node tools/indexnow.mjs --dry-run --all prints what would be sent, node tools/indexnow.mjs --all sends every sitemap URL, node tools/indexnow.mjs /privacy/ sends given paths, or run the workflow from the Actions tab (tick "all" for every URL).

No page, sitemap or other site content is changed.

🤖 Generated with Claude Code

Adds tools/indexnow.mjs (no dependencies) and a workflow that runs it after
every push to main that changes a page or the sitemap, once Cloudflare Pages
has had time to publish. It sends only the pages whose HTML changed, to
Bing, Yandex and other IndexNow engines. A failed ping logs a warning and
never fails the workflow. Adds the public IndexNow key file.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
@dpdev69 dpdev69 self-assigned this Nov 19, 2026
@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying upright with  Cloudflare Pages  Cloudflare Pages

Latest commit: f49e866
Status: ✅  Deploy successful!
Preview URL: https://4e3790eb.upright-2ev.pages.dev
Branch Preview URL: https://claude-indexnow-ping.upright-2ev.pages.dev

View logs

@dpdev69
dpdev69 merged commit a222732 into main Nov 19, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant