Cache Tags for Cloudflare
Precise Cloudflare cache purging for WordPress: adds Cache-Tag headers and purges only affected posts, pages, and terms.
Escolha sólida
Cache Tags for Cloudflare is a solid plugin choice in 2026, with a few things worth checking first. It runs on 10+ sites, is rated 5/5 and was last updated 4 months ago, and scores 63/100 on our health check.
- Testado com as últimas WordPress (7.1)
- Pequena base de usuários (10+ instalações ativas)
- Muito poucos comentários até agora
- Precisa de PHP 8.3 ou mais recente
Como ele se acumula?
Lado a lado em instalações, atualizações, avaliações e suporteDownloads diários
Os picos de download geralmente seguem uma nova versão — cada site que atualiza automaticamente é um download.
Rankings
Where Cache Tags for Cloudflare stands todayWordPress.org Classificações de pesquisa
Posição ao vivo na pesquisa de plugins, top 100| Palavra chave | Posição |
|---|---|
| esconderijo | >100 |
| cache-tag | #36 |
| cdn | >100 |
| cloudflare | #53 |
| Purge | #94 |
Adoção da versão
Compartilhamento de sites ativos por lançamento.
Divisão de classificação
★★★★★ ★★★★★ 5 de 1 comentários
About Cache Tags for Cloudflare
From the official readme · v1.5.2Descrição
Cache Tags for Cloudflare does two things:
- Tagging — adds a
Cache-TagHTTP response header to singular posts, pages, custom post types and taxonomy terms so Cloudflare can invalidate them by tag. - Purging — calls the Cloudflare API to purge the relevant tags when content changes (post publish/update/trash/delete and taxonomy term edits).
The two features can be enabled independently.
Works on any Cloudflare plan. The Cache-Tag header and purge-by-tag are available on all Cloudflare plans (Free, Pro, Business, and Enterprise); purge API rate limits scale with your plan.
Default tags
For singular content the plugin emits:
contentb{id}(site scope:b1on single site,b{blog_id}on multisite)b{id}-p{ID}b{id}-pt-{post_type}b{id}-t{term_id}for every public taxonomy term the post belongs to
Example header:
Cache-Tag: content,b1,b1-p42,b1-pt-post,b1-t5
Term tags use the numeric term ID (b1-t5), so they stay stable when a term is renamed or its slug changes.
Credentials
Provide a scoped Cloudflare API token (Zone → Cache Purge permission) and a Zone ID. Define them in wp-config.php for best security:
define( 'CACHE_TAGS_CF_API_TOKEN', 'your-scoped-token' );
define( 'CACHE_TAGS_CF_ZONE_ID', 'your-zone-id' );
When these constants are defined they take precedence and the settings fields become read-only. Otherwise enter them under Settings → Cache Tags.
Purge tools
The Settings → Cache Tags screen has a Purge tab for manual, on-demand purges by group: a whole post type, a taxonomy term, everything, or raw comma-separated tags. Saving valid credentials on the Settings tab automatically verifies the Cloudflare connection and unlocks the purge tools.
Automatic purging
When Auto-purge on changes is enabled and valid credentials are set, the plugin purges the affected tags automatically on these events:
- Post published, updated, trashed, or untrashed (any transition to or from the published status) — purges
b{id}-p{ID}plus the post’sb{id}-t{term_id}tags. - Post permanently deleted — purges
b{id}-p{ID}and itsb{id}-t{term_id}tags. - Taxonomy term edited or deleted — purges
b{id}-t{term_id}.
Only public post types and taxonomies are considered; revisions and autosaves are ignored. Tags collected during a request are de-duplicated and sent as a single batched purge after the response (in Cloudflare’s 30-tags-per-request batches). Draft-only edits, comments, menu/widget/theme changes, and plugin/core updates do not trigger a purge — use the Purge tab, WP-CLI, or the cache_tags_for_cloudflare/purge_tags filter for those. Static files such as images are served outside WordPress and are not tagged or purged by tag.
Hooks and programmatic purging
The plugin exposes hooks for customizing tags and purging from your own code:
- Filters:
cache_tags_for_cloudflare/tags,cache_tags_for_cloudflare/purge_tags - Result actions:
cache_tags_for_cloudflare/purged,cache_tags_for_cloudflare/purge_failed - Programmatic purging:
cache_tags_for_cloudflare/purge_post,/purge_terms,/purge_post_type,/purge_all,/purge
See the Developer guide for full documentation and examples.
Wp-cli
wp cache-tags purge --post-type=page
wp cache-tags purge --taxonomy=category --terms=news,sport
wp cache-tags purge --post=42
wp cache-tags purge --tags=b1-t5,content
wp cache-tags purge --all
wp cache-tags verify
On multisite, --all purges only the current subsite (via its b{id} tag). To purge every site sharing the Cloudflare zone at once, purge the global content tag: wp cache-tags purge --tags=content.
Serviços externos
This plugin connects to the Cloudflare API (https://api.cloudflare.com) to verify your credentials and to purge cached content by cache tag. Cloudflare is required for the plugin’s purging feature to work; the tagging feature (emitting Cache-Tag headers) works without contacting any external service.
The plugin contacts Cloudflare in the following cases, and only after you have provided a Cloudflare API token and Zone ID:
- Verifying credentials — when you save credentials on the settings screen or run
wp cache-tags verify, the plugin callsGET https://api.cloudflare.com/client/v4/user/tokens/verify. It sends your API token (in theAuthorizationheader) so Cloudflare can confirm the token is valid. - Purging cache — when content changes and auto-purge is enabled, or when you purge manually via the settings screen or
wp cache-tags purge, the plugin callsPOST https://api.cloudflare.com/client/v4/zones/{zone-id}/purge_cache. It sends your API token (in theAuthorizationheader), your Zone ID (in the request URL), and the list of cache tags to purge (in the request body). It does not send post content, personal data, or visitor information.
No data is sent to Cloudflare until you configure credentials, and no request is made unless one of the actions above is triggered.
Cloudflare is a third-party service provided by Cloudflare, Inc. By using this plugin’s purging feature you agree to Cloudflare’s terms and privacy policy:
- Terms of Service: https://www.cloudflare.com/website-terms/
- Privacy Policy: https://www.cloudflare.com/privacypolicy/
Instalação
- Upload the plugin to
/wp-content/plugins/cache-tags-for-cloudflareor install it from the Plugins screen. - Ative o plugin.
- Go to Settings → Cache Tags and add your Cloudflare API token and Zone ID (or define the constants in
wp-config.php).
Log de Changes
1.5.2
- Changed: Tested up to WordPress 7.1.
- Changed: Plugin URI now points to the WordPress.org listing.
- Changed: Updated dev/build dependencies to clear security advisories (no change to the shipped plugin).
1.5.1
- Fixed: Release workflow no longer runs twice per release, so the WordPress.org deployment no longer reports a spurious failure.
- Fixed: Build artifacts (the staging copy and generated zip) are excluded from the distributed plugin, so the download no longer contains a nested duplicate of itself.
1.5.0
- Fixed: The Purge tab no longer locks itself on every page load. Verification state is stored server-side, so a site with saved credentials opens with the purge tools ready instead of requiring a trip to Settings → Test connection first.
- Added: Persistent connection status on the Settings tab: not configured, saved-but-untested, connected with the time of the last successful test, or the error Cloudflare returned.
- Added: Tag previews under each purge tool showing the exact cache tag that will be sent (e.g.
b1-pt-post). - Added: Help text and a link to Cloudflare’s token screen for the API token and Zone ID fields.
- Changed: “Purge everything” now confirms in a WordPress modal that states exactly what gets purged, replacing the browser’s native confirm dialog.
- Changed: Result notices moved to a fixed corner stack so feedback is visible from the purge buttons; successes auto-dismiss, errors stay.
- Changed: The settings screen opens on Settings when no credentials are stored, and on Purge otherwise.
- Changed: Debug logging and raw-tag purging moved into collapsed “Advanced” sections; credential fields no longer stretch the full window width.
- Changed: The three “Purge” buttons now have distinct accessible labels.
1.4.1
- Changed: The purge-failure admin notice now links to the Cache Tags settings page so credentials can be fixed in one click.
- Changed: Added WordPress.org as the primary install option in the README.
- Security: Bumped
fast-urito 3.1.4 to resolve a high-severity advisory (build-only dependency; nothing ships in the plugin).
1.4.0
- Added: Purge by URL. When a post is published (including a draft or scheduled post going live), its permalink is now purged by URL alongside its cache tags. This invalidates responses that carry no cache tag — most importantly a cached
404at a URL that has since become a real post — which tag-based purging alone cannot reach. - Added:
cache_tags_for_cloudflare/purge_urlsaction hook to purge arbitrary URLs programmatically. - Added:
wp cache-tags purge --urls=<urls>WP-CLI flag (comma-separated URLs). - Added:
cache_tags_for_cloudflare/purged_urlsandcache_tags_for_cloudflare/purge_urls_failedhooks fired after an automatic URL purge. URL purges are sent as a separate Cloudflare request from tag purges and must match the cached request exactly (scheme, host, trailing slash, query).
1.3.1
- Fixed: “Purge everything” (the Purge tab,
wp cache-tags purge --all, and thecache_tags_for_cloudflare/purge_allhook) now purges the blog-scopedb{id}tag instead of the sharedcontenttag. On multisite this keeps the purge scoped to the current subsite instead of clearing every site sharing the Cloudflare zone. To purge every site in the zone at once, purge thecontenttag directly (e.g.wp cache-tags purge --tags=content).
Para desenvolvedores
Este é o seu plugin? Mostre os números.
Adicione um crachá ao vivo ao seu site, Documentos ou Readme do GitHub. Ele é atualizado por conta própria - nenhuma conta necessária.
Best Cache Tags for Cloudflare alternatives
Todos os plugins de cache →FAQ
Cache Tags for Cloudflare: quick answers
Respostas diretas, extraídas de dados ao vivo WordPress.org.
Fonte: WordPress.org
Is Cache Tags for Cloudflare free?
Yes. Cache Tags for Cloudflare is free to download and use from the official WordPress.org plugin directory.
Is Cache Tags for Cloudflare safe to use in 2026?
Cache Tags for Cloudflare is a solid plugin choice in 2026, with a few things worth checking first. It runs on 10+ sites, is rated 5/5 and was last updated 4 months ago, and scores 63/100 on our health check.
How many websites use Cache Tags for Cloudflare?
Cache Tags for Cloudflare is active on 10+ WordPress websites and has been downloaded 524 times since it launched in July 2026. It was downloaded 91 times in the last 30 days.
Does Cache Tags for Cloudflare work with WordPress 7.1?
Yes. The developer has tested Cache Tags for Cloudflare up to WordPress 7.1.5, the latest release. It requires WordPress 6.8 or newer.
What PHP version does Cache Tags for Cloudflare need?
Cache Tags for Cloudflare requires PHP 8.3 or higher. Most hosts run PHP 8.x today, so it works on any modern WordPress hosting.
When was Cache Tags for Cloudflare last updated?
The latest version, 1.5.2, was released on August 5, 2026 (4 months ago).
Who makes Cache Tags for Cloudflare?
Cache Tags for Cloudflare is developed and maintained by Per Søderlind.
What are the best alternatives to Cache Tags for Cloudflare?
The most popular alternatives to Cache Tags for Cloudflare are WP Super Cache (1M+ installs), WP Fastest Cache (1M+ installs) and WP-Optimize (1M+ installs).
Alimentado por PageForge
Um modelo e uma planilha. Uma página real para cada pesquisa.
PageForge Transforma cada linha de um CSV em uma página WordPress com seu próprio título, URL, SEO campos e esquema, construído no layout que você já desenhou. Gratuito em WordPress.org.
- CSV e XLSX, mais Google Sheets em Profissional e Empresarial
- Seu próprio título, URL, SEO campos e esquema para cada página
- Funciona com o editor de blocos, Elementor, Divi e Avada
- Gratuito em WordPress.org, sem cartão de crédito


