{"id":29956,"date":"2023-03-10T04:24:32","date_gmt":"2023-03-10T04:24:32","guid":{"rendered":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/"},"modified":"2026-02-09T04:48:21","modified_gmt":"2026-02-09T04:48:21","slug":"how-to-clear-the-cache-for-a-selected-number-of-pages-regularly","status":"publish","type":"knowledgebase","link":"https:\/\/www.wpstaq.com\/nz\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/","title":{"rendered":"How to clear the cache for a selected number of pages regularly"},"content":{"rendered":"<h2>Question<\/h2>\n<p>Rather than dumping the entire site\u2019s cache regularly, how can I schedule for the cache to clear the cache for only specific pages?<\/p>\n<h2>Answer<\/h2>\n<p>You can do this using the built-in Staq <span style=\"font-weight: 600;\">Cron Manager<\/span>\u00a0for clearing cache by page ID.<\/p>\n<ul>\n<li>Go to your site in the Staq Panel and click <strong>Cron Manager<\/strong>\u00a0and click <strong>Add<\/strong>:<\/li>\n<\/ul>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-38566\" src=\"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/staq-cron-manager.png\" alt=\"\" width=\"1424\" height=\"608\" srcset=\"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/staq-cron-manager.png 1424w, https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/staq-cron-manager-300x128.png 300w, https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/staq-cron-manager-1024x437.png 1024w, https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/staq-cron-manager-768x328.png 768w\" sizes=\"auto, (max-width: 1424px) 100vw, 1424px\" \/><\/p>\n<p>&nbsp;<\/p>\n<p>Select how often you want the job to run using the <span style=\"font-weight: 600;\">Job interval<\/span>.<\/p>\n<p>In the command field, enter:<\/p>\n<p><code>wp wpstaq clear-cache --post_id=PAGE_ID<\/code><\/p>\n<p>Replace <span style=\"font-weight: 600;\">PAGE_ID<\/span> with the ID of the page you want to clear the cache for.<\/p>\n<p>If you are not sure what the page ID is:<\/p>\n<ul>\n<li>Open the page in WordPress.<\/li>\n<li>Click <span style=\"font-weight: 600;\">Edit<\/span>.<\/li>\n<li>Look at the URL in your browser and copy the numeric ID from the address bar:<\/li>\n<\/ul>\n<p><img decoding=\"async\" class=\"aligncenter\" src=\"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2022\/05\/page-id.png\" alt=\"\" \/><\/p>\n<p>This is how a completed cron job looks once the command and interval are set:<\/p>\n<p><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter size-full wp-image-38567\" src=\"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/cron-job-example.png\" alt=\"\" width=\"1035\" height=\"472\" srcset=\"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/cron-job-example.png 1035w, https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/cron-job-example-300x137.png 300w, https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/cron-job-example-1024x467.png 1024w, https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/03\/cron-job-example-768x350.png 768w\" sizes=\"auto, (max-width: 1035px) 100vw, 1035px\" \/><\/p>\n<p>Click <span style=\"font-weight: 600;\">Save<\/span> to activate the job.<\/p>\n<p>You can create multiple cron jobs if you need to regularly clear the cache for more than one page.<\/p>\n","protected":false},"featured_media":29679,"parent":0,"template":"","class_list":["post-29956","knowledgebase","type-knowledgebase","status-publish","has-post-thumbnail","hentry","categories-caching","categories-cron-jobs"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.8 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>How to clear the cache for a selected number of pages regularly - Managed Hosting Platform for WordPress<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"How to clear the cache for a selected number of pages regularly - Managed Hosting Platform for WordPress\" \/>\n<meta property=\"og:description\" content=\"Question Rather than dumping the entire site\u2019s cache regularly, how can I schedule for the cache to clear the cache for only specific pages? Answer You can do this using the built-in Staq Cron Manager\u00a0for clearing cache by page ID. Go to your site in the Staq Panel and click Cron Manager\u00a0and click Add: &nbsp;&hellip;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/\" \/>\n<meta property=\"og:site_name\" content=\"Managed Hosting Platform for WordPress\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/staqhosting\/\" \/>\n<meta property=\"article:modified_time\" content=\"2026-02-09T04:48:21+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/05\/Clear-cache-for-individual-pages.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1000\" \/>\n\t<meta property=\"og:image:height\" content=\"500\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data1\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/\",\"url\":\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/\",\"name\":\"How to clear the cache for a selected number of pages regularly - Managed Hosting Platform for WordPress\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.wpstaq.com\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/Clear-cache-for-individual-pages.png\",\"datePublished\":\"2023-03-10T04:24:32+00:00\",\"dateModified\":\"2026-02-09T04:48:21+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/#breadcrumb\"},\"inLanguage\":\"en-nz\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-nz\",\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.wpstaq.com\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/Clear-cache-for-individual-pages.png\",\"contentUrl\":\"https:\\\/\\\/www.wpstaq.com\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/Clear-cache-for-individual-pages.png\",\"width\":1000,\"height\":500},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/knowledgebase\\\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.wpstaq.com\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"How to clear the cache for a selected number of pages regularly\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/#website\",\"url\":\"https:\\\/\\\/www.wpstaq.com\\\/\",\"name\":\"Managed Hosting Platform for WordPress\",\"description\":\"\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.wpstaq.com\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-nz\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/#organization\",\"name\":\"Staq\",\"alternateName\":\"WPStaq\",\"url\":\"https:\\\/\\\/www.wpstaq.com\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-nz\",\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.wpstaq.com\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/cropped-LogoNoText.png\",\"contentUrl\":\"https:\\\/\\\/www.wpstaq.com\\\/wp-content\\\/uploads\\\/2023\\\/05\\\/cropped-LogoNoText.png\",\"width\":512,\"height\":512,\"caption\":\"Staq\"},\"image\":{\"@id\":\"https:\\\/\\\/www.wpstaq.com\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/staqhosting\\\/\",\"https:\\\/\\\/www.linkedin.com\\\/company\\\/wpstaq\"]}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"How to clear the cache for a selected number of pages regularly - Managed Hosting Platform for WordPress","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/","og_locale":"en_US","og_type":"article","og_title":"How to clear the cache for a selected number of pages regularly - Managed Hosting Platform for WordPress","og_description":"Question Rather than dumping the entire site\u2019s cache regularly, how can I schedule for the cache to clear the cache for only specific pages? Answer You can do this using the built-in Staq Cron Manager\u00a0for clearing cache by page ID. Go to your site in the Staq Panel and click Cron Manager\u00a0and click Add: &nbsp;&hellip;","og_url":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/","og_site_name":"Managed Hosting Platform for WordPress","article_publisher":"https:\/\/www.facebook.com\/staqhosting\/","article_modified_time":"2026-02-09T04:48:21+00:00","og_image":[{"width":1000,"height":500,"url":"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/05\/Clear-cache-for-individual-pages.png","type":"image\/png"}],"twitter_card":"summary_large_image","twitter_misc":{"Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/","url":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/","name":"How to clear the cache for a selected number of pages regularly - Managed Hosting Platform for WordPress","isPartOf":{"@id":"https:\/\/www.wpstaq.com\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/#primaryimage"},"image":{"@id":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/#primaryimage"},"thumbnailUrl":"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/05\/Clear-cache-for-individual-pages.png","datePublished":"2023-03-10T04:24:32+00:00","dateModified":"2026-02-09T04:48:21+00:00","breadcrumb":{"@id":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/#breadcrumb"},"inLanguage":"en-nz","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/"]}]},{"@type":"ImageObject","inLanguage":"en-nz","@id":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/#primaryimage","url":"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/05\/Clear-cache-for-individual-pages.png","contentUrl":"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/05\/Clear-cache-for-individual-pages.png","width":1000,"height":500},{"@type":"BreadcrumbList","@id":"https:\/\/www.wpstaq.com\/knowledgebase\/how-to-clear-the-cache-for-a-selected-number-of-pages-regularly\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.wpstaq.com\/"},{"@type":"ListItem","position":2,"name":"How to clear the cache for a selected number of pages regularly"}]},{"@type":"WebSite","@id":"https:\/\/www.wpstaq.com\/#website","url":"https:\/\/www.wpstaq.com\/","name":"Managed Hosting Platform for WordPress","description":"","publisher":{"@id":"https:\/\/www.wpstaq.com\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.wpstaq.com\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-nz"},{"@type":"Organization","@id":"https:\/\/www.wpstaq.com\/#organization","name":"Staq","alternateName":"WPStaq","url":"https:\/\/www.wpstaq.com\/","logo":{"@type":"ImageObject","inLanguage":"en-nz","@id":"https:\/\/www.wpstaq.com\/#\/schema\/logo\/image\/","url":"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/05\/cropped-LogoNoText.png","contentUrl":"https:\/\/www.wpstaq.com\/wp-content\/uploads\/2023\/05\/cropped-LogoNoText.png","width":512,"height":512,"caption":"Staq"},"image":{"@id":"https:\/\/www.wpstaq.com\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/staqhosting\/","https:\/\/www.linkedin.com\/company\/wpstaq"]}]}},"_links":{"self":[{"href":"https:\/\/www.wpstaq.com\/nz\/wp-json\/wp\/v2\/knowledgebase\/29956","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.wpstaq.com\/nz\/wp-json\/wp\/v2\/knowledgebase"}],"about":[{"href":"https:\/\/www.wpstaq.com\/nz\/wp-json\/wp\/v2\/types\/knowledgebase"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.wpstaq.com\/nz\/wp-json\/wp\/v2\/media\/29679"}],"wp:attachment":[{"href":"https:\/\/www.wpstaq.com\/nz\/wp-json\/wp\/v2\/media?parent=29956"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}