Roll tokens

Last updated Apr 20, 2026 If your token is lost or compromised, you can either create a new token or roll your token to generate a new secret. Rolling your API token into a new one will invalidate the previous token, but the access and permissions will be the same as the previous API token. The new token uses the scannable format, which allows credential scanning tools to detect leaked tokens.

To roll your API token:

  1. Go to My Profile > API Tokens. Go to API Tokens ↗
  2. Next to the API token you want to roll, select the three dot icon > Roll.
  3. Select Confirm to generate a new API token.

Was this helpful?

YesNo

On this page

Roll tokens - 图1Docs

{"@context":"https://schema.org","@type":"TechArticle","@id":"https://developers.cloudflare.com/fundamentals/api/how-to/roll-token/#page","headline":"Roll tokens","description":"Regenerate Cloudflare API token secrets to rotate credentials and maintain account security.","url":"https://developers.cloudflare.com/fundamentals/api/how-to/roll-token/","inLanguage":"en","image":"https://developers.cloudflare.com/fundamentals/api/how-to/roll-token/og.png?v=2494fa0d8284674c","dateModified":"2026-04-20","publisher":{"@type":"Organization","name":"Cloudflare","description":"One platform for your apps, agents, and workforce. Build, secure, and scale without managing infrastructure","url":"https://www.cloudflare.com/","sameAs":["https://github.com/cloudflare","https://www.linkedin.com/company/cloudflare","https://x.com/cloudflare"],"logo":{"@type":"ImageObject","url":"https://developers.cloudflare.com/logo.svg"},"address":{"@type":"PostalAddress","streetAddress":"101 Townsend St","addressLocality":"San Francisco","addressRegion":"CA","postalCode":"94107","addressCountry":"US"},"contactPoint":[{"@type":"ContactPoint","contactType":"Customer Support","url":"https://support.cloudflare.com/","availableLanguage":["English"]},{"@type":"ContactPoint","contactType":"Sales","url":"https://www.cloudflare.com/contact/","availableLanguage":["English"]}]},"isPartOf":{"@type":"WebSite","@id":"https://developers.cloudflare.com/#website","name":"Cloudflare Docs","url":"https://developers.cloudflare.com/"}}


description: Track Cloudflare API deprecations, removal timelines, and replacement endpoints. title: API deprecations image: https://developers.cloudflare.com/fundamentals/api/reference/deprecations/og.png?v=ccd3b263026341d8


Skip to content

Documentation Index
Fetch the complete documentation index at: https://developers.cloudflare.com/fundamentals/llms.txt
Use this file to discover all available pages before exploring further.