# Leaked Slack Legacy Token? Revoke the xoxo/xoxa Token

> Slack legacy token (xoxo, xoxa) exposed on GitHub? Revoke it, review workspace access and apps. Step-by-step guide.

Source: https://leakwatch.net/secrets/slack-legacy-token

---

[LeakWatch](/)

[Product](/product)[Live feed](/leaks)[Guides](/secrets)[Blog](/blog)[Free scan](/)

1.  [Home](/)
2.  [Secrets](/secrets)
3.  Slack Legacy Token

Messaging · Secret guide

# Leaked Slack Legacy Token: what to do in the first hour

High severityDetected onlyLast verified October 30, 2026 · 5 min read

Slack legacy tokens come from older ways of integrating with Slack: workspace tokens and the original bot-and-user tokens that predate today’s granular app permissions. Slack has retired or deprecated these models, but a token that was never revoked may still be valid. Such a token tends to have broad access to a workspace, since it was issued before scopes were fine grained, and it may act as the user who created it. That is why a leaked legacy token deserves the same urgency as a current one: it may open channels, messages and files. Revoke it first, then investigate what it could see.

[Check your GitHub account for leaked secrets — free](/)

Provider

Slack

Severity

High

Impact

SaaS account access and billing

Checked live by LeakWatch

No

## What a Slack Legacy Token looks like

Legacy tokens start with `xox` followed by `o` or `a`, and then dash-separated parts:

```text
xoxo-NNNN-NNNN-NNNN-hhhh…   combined legacy token: three numeric ids, then hex (masked)
xoxa-XXXX…                  workspace token (masked): a letters-and-digits body after the prefix
```

The first form, `xoxo-`, is followed by three groups of digits and a hexadecimal tail. The second form, `xoxa-` or `xoxo-`, is followed by a body of 8 to 48 letters and digits, sometimes preceded by a single digit and a dash. They show up as `SLACK_TOKEN` or `SLACK_LEGACY_TOKEN` in old bots, scripts, build files and integration configuration. The most important distinction is with the current tokens: bot tokens start with `xoxb-` and user tokens with `xoxp-`, and those are covered by [Slack API token](/secrets/slack-api-token). An `xoxa-` prefix is also used by some current app tokens, so the prefix alone does not prove that a token is legacy.

## How Slack Legacy Tokens get leaked

-   **Old bots and scripts.** Projects started when legacy tokens were the easy option, never updated, with the token in the source or a config file.
-   **Forgotten repositories.** Archived or personal repositories that were made public, with the token still in the history.
-   **Backups and dotfiles.** Shell profiles, `.env` files and chat client configuration copied into a public dotfiles repository.
-   **Integration configuration.** A third-party tool’s settings file with the token pasted in, exported or shared for support.
-   **CI definitions.** An old pipeline posting build results to Slack with the token written in the file.

## What to do in the first hour

1.  **Revoke the token.** Use the Slack API site to find the legacy token page of the person who generated it, or the app that issued it, and revoke it. If you cannot find the page, consider whether migrating to a current app with scoped tokens is the better answer, and revoke access for the integration in the workspace settings.
2.  **Replace it with a current token.** Create a Slack app with only the scopes needed, install it and use its bot token. Store it in a secret manager and deploy it.
3.  **Identify who generated it.** A legacy token acts as a person, so find out whose it was and what that person can see. If it belonged to an admin, treat the exposure as larger.
4.  **Audit activity.** Workspace owners and admins can review access logs and, on plans that include it, audit logs. Look for logins or API calls from unknown addresses, exports, new apps, new webhooks and changes to membership.
5.  **Check what was created.** Review installed apps, incoming webhooks and custom integrations, and remove any you do not recognize. Rotate any webhook URL that was exposed; see [Slack webhook URL](/secrets/slack-webhook-url).
6.  **Clean up the code** and its history. See [I accidentally pushed an API key to GitHub](/blog/i-accidentally-pushed-an-api-key-to-github).

Not sure what else leaked from the same repository? [Run a free scan](/).

[Not sure what else leaked? Run a free scan.](/)

## Revoke it at Slack

Legacy tokens are tied to the account or the integration that issued them, and Slack has been moving people away from them. Start from the Slack API console, signed in as the owner of the token or as a workspace admin, and look for the section where tokens or installed apps are listed. If you cannot find the legacy token, an admin can remove the integration from the workspace. A person has not confirmed the exact menu wording for this guide, and the interface can change, so follow the Slack documentation at [https://docs.slack.dev/](https://docs.slack.dev/) for the current way to revoke or retire legacy tokens.

## How LeakWatch detects it

There are two rules. The one called Slack Legacy Token matches `xoxo-`, three numeric groups separated by dashes and a hexadecimal tail, so `xoxo-` followed by anything else is not reported. The one called Slack Legacy Workspace Token matches `xoxa-` or `xoxo-`, then an optional single digit and dash, then 8 to 48 letters and digits. A shorter body is ignored, and the other prefixes (`xoxb-`, `xoxp-`) are left to other rules. Neither rule needs a variable name. The severity of both is **high**. Because `xoxa-` can also appear in a current token, a match is worth checking by hand. This type is not checked live: LeakWatch does not send any request to Slack with the token it found.

LeakWatch detects this format but does **not** check it live: it can tell you the key is exposed, not whether it still works. Assume it does until you have revoked it.

## FAQ

Are legacy tokens still valid?

They can be, if they were never revoked. Slack has deprecated the models that issued them, but do not assume that an old token is dead. Treat a leak as real until you have revoked it.

What is the difference with a bot token?

A bot token starts with `xoxb-` and has scopes chosen when the app was installed. A legacy token comes from older, broader permission models and may act as a person.

Should I just migrate instead of revoking?

Do both. Revoke the leaked token now, and move the integration to a current Slack app with narrow scopes so that you do not depend on legacy tokens again.

## Related

-   [Slack API Token](/secrets/slack-api-token)
-   [Slack App-Level Token](/secrets/slack-app-level-token)
-   [Slack Webhook URL](/secrets/slack-webhook-url)
-   [I accidentally pushed an API key to GitHub](/blog/i-accidentally-pushed-an-api-key-to-github)
-   [Which vendors leak most this week](/leaks/trends)
-   [All secret guides](/secrets)

[Get alerted next time a secret leaks — create a free account](/)

LeakWatch is not affiliated with Slack.

![Gabriel Diyan, founder of LeakWatch](/brand/Photo-Gabriel-Diyan.webp)

Gabriel Diyan (0xCr0c0)

Cybersecurity student, founder of LeakWatch. I built and run the scanner described here — the detection patterns, the false-positive classifier and the provider validators are mine. [More about who I am](/about).

[GitHub](https://github.com/Leakwatch-Scan) · [X](https://x.com/LeakwatchScan) · [LinkedIn](https://www.linkedin.com/in/gabriel-diyan-80a378375) · [GitHub (personal)](https://github.com/crocogab)

LeakWatch

Secrets leak into public commits every minute. This watches the forges for yours. Built and run by [Gabriel Diyan](/about), a cybersecurity student — [why LeakWatch exists](/about).

Scan

-   [Product](/product)
-   [Live feed](/leaks)
-   [Trends](/leaks/trends)
-   [API docs](/docs)
-   [CI/CD](/docs?tab=ci)

Read

-   [Blog](/blog)
-   [Secret guides](/secrets)
-   [Changelog](/changelog)
-   [About](/about)

Verify

-   [Security](/security)
-   [Privacy](/privacy)
-   [Terms](/terms)
-   [Legal](/legal)
-   [Contact](/contact)
-   [Status](https://status.leakwatch.net)

© 2026 LeakWatch

[GitHub](https://github.com/Leakwatch-Scan)[X](https://x.com/LeakwatchScan)
