# Where are my social media tokens stored? Cloud vs local-first

> Your tokens live where your scheduler runs: a vendor's database for cloud tools, a file on your machine for local-first ones. How to check and revoke.

Author: Dominic Frei. Published 2026-11-24, updated 2026-11-24.
Canonical: https://pendpost.com/blog/local-first-social-media-scheduler-security

## Key takeaways

- When you connect a social account to a scheduler, the platform issues that app an access token, and the token is stored wherever the scheduler runs.
- A cloud scheduler keeps tokens on its own servers so it can post while your computer is off; a local-first tool keeps them in a file on your machine.
- Tokens are bearer credentials: whoever holds one can act within its scopes until it expires or you revoke it, so scopes and lifetimes matter as much as storage.
- Every major platform lets you revoke an app's access from your account settings, but revoking does not delete data the app already collected.
- Question scopes a scheduler does not need for posting, such as direct message access or ad account management.

Your social media tokens are stored wherever your scheduler runs. When you connect an account, the platform issues the app an access token, often with a refresh token, and the app keeps both. A cloud scheduler stores them on its own servers, usually encrypted, because those servers have to publish while your laptop is closed. A local-first tool stores them in a file on your own machine. In both cases the token works as a bearer credential. Whoever holds it can act as you, within the scopes you granted, until it expires or you revoke the app in the platform's settings.

## Where does a cloud scheduler keep your tokens?

A cloud scheduler keeps your tokens in its own database or secrets store, and it has to. The whole point of a hosted tool is that its servers fire your 9 a.m. post while you are asleep, and they can only do that with a usable credential on hand.

Most services encrypt tokens at rest. Good, but know the limit. The service must be able to decrypt a token at publish time, so encryption protects against a stolen disk or a leaked database dump without the key. It does not protect against a compromise of the running service itself.

The other property is concentration. One store holds the tokens of every customer, which makes it a valuable target. It also usually means a security team whose full time job is defending it. I'd rather state that trade plainly than pretend one side has no cost.

## Where does a local-first scheduler keep your tokens?

A local-first scheduler keeps your tokens on your own computer, typically in a config or `.env` file that only your user account can read. No shared server holds them, so a breach of the maker's servers exposes no stored tokens of yours.

The trade moves to your machine. Anything that can read your files as your user (malware, a synced folder you forgot about, a careless backup) can read the tokens too. And a scheduler on a laptop only posts while the laptop is awake, unless the platform schedules natively or you run the tool on an always-on host.

| | Cloud scheduler | Local-first scheduler |
| --- | --- | --- |
| Where tokens live | The vendor's database or secrets store | A file on your machine |
| Who can use them | The vendor's running service | Processes running as your user |
| What one breach exposes | Many customers at once | One machine |
| Posts when your computer is off | Yes | Only with native platform scheduling or an always-on host |
| Who patches and monitors | The vendor | You |

## What can someone do with a leaked token?

With a leaked token, someone can do whatever its scopes allow until it expires or is revoked. [RFC 6750](https://www.rfc-editor.org/rfc/rfc6750), the OAuth bearer token spec, defines a bearer token as one that any party in possession of it can use, with no proof of a key required. So two numbers decide how bad a leak is: the scopes and the lifetime.

Lifetimes vary a lot. As of November 2026, the platforms document these:

| Platform | Documented token lifetime |
| --- | --- |
| Meta (Facebook, Instagram) | Long-lived user tokens last about 60 days; long-lived Page tokens have no expiration date and end only under certain conditions ([Meta](https://developers.facebook.com/docs/facebook-login/guides/access-tokens/get-long-lived)) |
| LinkedIn | Access tokens 60 days, programmatic refresh tokens one year ([Microsoft Learn](https://learn.microsoft.com/en-us/linkedin/shared/authentication/programmatic-refresh-tokens)) |
| X (OAuth 2.0) | Access tokens two hours by default; with `offline.access` a refresh token keeps the app connected until you revoke it ([X docs](https://docs.x.com/fundamentals/authentication/oauth-2-0/authorization-code)) |
| Google (YouTube) | Refresh tokens from an app in "Testing" status with an external user type expire in 7 days, unless only basic profile scopes are requested ([Google](https://developers.google.com/identity/protocols/oauth2)) |

Any tool that posts unattended needs a credential that outlives a working day. Fair enough. It does mean that revocation, not expiry, is your real off switch.

## Which OAuth scopes should I question?

Question any scope that does more than read your profile and publish posts. A scheduler needs to publish. It rarely needs your messages or your ad account. These are the ones I would ask a vendor about, with each platform's own description:

| Scope | What the platform says it allows | Needed to schedule posts? |
| --- | --- | --- |
| `pages_messaging` (Meta) | Manage and access Page conversations in Messenger | No |
| `instagram_manage_messages` (Meta) | Read and respond to Instagram Direct messages | No |
| `ads_management` (Meta) | Read and manage the ad account the app owns | Not for organic posts |
| `dm.read`, `dm.write` (X) | Read all your Direct Messages; send and manage them | No |
| `youtube.force-ssl` (Google) | See, edit, and permanently delete your videos, ratings, comments and captions | Only for comments and captions |
| `read`, `write` (Mastodon) | Broad read and write; Mastodon recommends granular scopes instead | Usually `write:statuses` and `write:media` are enough |

Sources: [Meta permissions reference](https://developers.facebook.com/docs/permissions), [X scopes](https://docs.x.com/fundamentals/authentication/oauth-2-0/authorization-code), [YouTube scopes](https://developers.google.com/youtube/v3/guides/auth/installed-apps), [Mastodon scopes](https://docs.joinmastodon.org/api/oauth-scopes/).

A broad scope is not proof of bad intent. Some features need one. pendpost's YouTube lane asks for `youtube.force-ssl`, for example, because posting captions and channel comments requires it. The test is whether the vendor can name the feature behind each scope.

## How do I check and revoke app access on each platform?

You revoke access in each platform's account settings, under the list of connected apps. As of November 2026, the official help pages give these paths:

| Platform | Where to revoke |
| --- | --- |
| Facebook | Profile picture > Settings & privacy > Settings > Business integrations (under Your activity) > Remove. Apps you logged into with Facebook sit under Apps and websites (Facebook Help Center, "How do I edit the privacy and settings for my business integrations") |
| Instagram | More > Settings > Website permissions > Apps and websites > Active > Remove (Instagram Help Center, "How to manage websites or apps connected to your Instagram") |
| LinkedIn | Me > Settings & Privacy > Data privacy > Other applications > Permitted services > Remove ([LinkedIn Help](https://www.linkedin.com/help/linkedin/answer/1207)) |
| X | Settings and privacy, then the Apps and sessions section > select the app > Revoke access ([X Help](https://help.x.com/en/managing-your-account/connect-or-revoke-access-to-third-party-apps)) |
| YouTube (Google Account) | Third-party connections page > filter "Access to your Google Account" > select the app > See details > Remove access ([Google Help](https://support.google.com/accounts/answer/13533235?hl=en)) |

A couple of practical notes. If a tool connected Instagram through your Facebook Page, look in Facebook's Business integrations as well as Instagram's own list. And revoking stops future access only. LinkedIn, Google, Facebook and Instagram all say an app may keep data it already received, so ask the developer to delete it if that matters to you.

Read these lists twice a year. The usual find is an app you tried once, forgot, and that can still post as you.

## How does pendpost store your tokens?

pendpost is a free, open-source, local-first scheduler, and its [security page](https://pendpost.com/security) states the model in a few lines. It binds `127.0.0.1` by default, your platform keys stay in your own `.env` file, and nothing phones home. Your tokens go only to the platforms you configure. It also rejects cross-origin browser requests and unknown Host headers, which loopback alone would not stop.

For the questions in this post, two details matter. First, the AI agent that drafts your posts never touches a secret. The [MCP setup guide](https://docs.pendpost.com/mcp-server) explains that you enter tokens yourself in a local command or the dashboard, which writes `.env` at mode `0600`, and the agent's config tool cannot set a secret at all. Second, if you deliberately run pendpost on a public host, a bearer token gate turns on, as described in the [always-on guide](https://docs.pendpost.com/always-on).

The trust boundary is your machine. Anything that can read your files as your user can read the credentials, the same as with any tool that keeps keys on disk. For people who would rather not run their own box, there is an optional 24/7 cloud service. It holds tokens encrypted per tenant in a vault, enforces the same approval gate on the server, and lets you move back to self-hosting. So it is the cloud trade from the top of this post, made knowingly, and the local install stays the default. For the publishing side of the same question, see [how to let an AI agent post safely](https://pendpost.com/blog/let-an-ai-agent-post-to-social-media-safely).

## Frequently asked questions

### Where are my social media tokens stored when I use a scheduling tool?

They are stored wherever the tool runs. A hosted scheduler keeps them in its own database or secrets store, usually encrypted, because its servers publish on your behalf. A local-first tool keeps them on your computer, for example in a .env file. The platform also keeps a record of the grant, which is what you see and revoke in your account settings.

### Can someone post as me if my scheduler's tokens leak?

Yes, within the scopes those tokens carry and until they expire or are revoked. OAuth access tokens are usually bearer tokens, and the OAuth bearer token spec says any party in possession of one can use it. Revoking the app in your platform settings is the fastest way to cut a leaked token off.

### Does revoking an app delete my data from it?

No. LinkedIn, Google, Facebook and Instagram all say that removing an app stops further access but does not delete data the app already received. To get that data deleted you have to ask the app's developer, usually through the contact in its privacy policy.

### Is a local-first scheduler more secure than a cloud one?

It has a different exposure, not automatically a smaller one. A local-first tool removes the shared server that holds many customers' tokens, but anything that can read your files as your user can read the tokens too. A cloud service puts the tokens behind a team whose job is to protect them, but it is a larger target. Pick the model whose risks you can manage.


## Sources

- [RFC 6750: OAuth 2.0 Bearer Token Usage](https://www.rfc-editor.org/rfc/rfc6750)
- [Meta: Long-lived access tokens](https://developers.facebook.com/docs/facebook-login/guides/access-tokens/get-long-lived)
- [Meta: Permissions reference](https://developers.facebook.com/docs/permissions)
- [LinkedIn (Microsoft Learn): Refresh tokens with OAuth 2.0](https://learn.microsoft.com/en-us/linkedin/shared/authentication/programmatic-refresh-tokens)
- [X: OAuth 2.0 authorization code flow with PKCE (scopes)](https://docs.x.com/fundamentals/authentication/oauth-2-0/authorization-code)
- [Google: Using OAuth 2.0 to access Google APIs](https://developers.google.com/identity/protocols/oauth2)
- [Google: OAuth 2.0 for installed apps (YouTube scopes)](https://developers.google.com/youtube/v3/guides/auth/installed-apps)
- [Mastodon: OAuth scopes](https://docs.joinmastodon.org/api/oauth-scopes/)
- [LinkedIn Help: Third-party applications data use](https://www.linkedin.com/help/linkedin/answer/1207)
- [X Help: Connect or revoke access to third-party apps](https://help.x.com/en/managing-your-account/connect-or-revoke-access-to-third-party-apps)
- [Google Account Help: Manage connections between your Google Account and third parties](https://support.google.com/accounts/answer/13533235?hl=en)
