Repository navigation
IndexNow: tell search engines which pages changed after each deploy - #13
Merged
Merged
Conversation
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>
Deploying folio with
|
| Latest commit: |
aa730c5
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://129cc333.folio-bn7.pages.dev |
| Branch Preview URL: | https://claude-indexnow-ping.folio-bn7.pages.dev |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
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 toapi.indexnow.org..github/workflows/indexnow.yml: runs on a push tomainthat changes a page (site/**.html) orsite/sitemap.xml. It waits two minutes for Cloudflare Pages to publish, then sends only the changed pages. No secrets, no third-party actions.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 --allprints what would be sent,node tools/indexnow.mjs --allsends 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