---
source_url: https://www.pubnub.com/docs/portal/keysets
title: Keysets
updated_at: 2026-06-04T11:10:43.566Z
---

> Documentation Index
> For a curated overview of PubNub documentation, see: https://www.pubnub.com/docs/llms.txt
> For the full list of all documentation pages, see: https://www.pubnub.com/docs/llms-full.txt


# Keysets

The **Keysets** subsection lets you configure PubNub features for each keyset.

:::warning Limit of 3 keysets for Free tier accounts
Effective February 3, 2025, all [Free tier](https://www.pubnub.com/pricing/) accounts are limited to a maximum of three keysets. If your account exceeds this limit, you must delete existing keysets to create new ones.
:::

![Keysets page with selected app and list of keysets](https://www.pubnub.com/assets/images/keysets-app-d1d17389714b5fbccebc3a8cff819d3e.png)

Each keyset overview page shows:

* Whether a keyset is of Testing or Production kind (depending on its purpose).
* Your app's publish, subscribe, and secret keys. Each keyset contains a publish and subscribe key pair that work together to authenticate your application. The publish key (starts with pub-c-) authorizes sending messages, and the subscribe key (starts with sub-c-) controls receiving messages and channel access.
* Current and available configuration options, like Presence, App Context, or Access Manager.
* Recommended links to SDKs that can help you use the keys to build PubNub-powered apps.

![Keyset details showing keys and feature configuration](https://www.pubnub.com/assets/images/keyset-details-27741ca7e39cdeab22e588d7bd2a0595.png)

## Feature configuration

When you choose an app, you see all keysets assigned to it. Select a keyset to view its configurable features, including:

* [Stream Controller](https://www.pubnub.com/docs/general/channels/subscribe#wildcard-subscribe)
* [Presence](https://www.pubnub.com/docs/general/presence/overview)
* [Access Manager](https://www.pubnub.com/docs/general/security/access-control)
* [Message Persistence](https://www.pubnub.com/docs/general/storage)
* [App Context](https://www.pubnub.com/docs/general/metadata/basics)
* [Mobile Push Notifications](https://www.pubnub.com/docs/general/push/send) Apple Push Credentials, Firebase Cloud Messaging
* [File Sharing](https://www.pubnub.com/docs/general/files)

Each feature has parameters that control how it works.

When you create a keyset, some features start with default options.

![Feature configuration section for a selected keyset](https://www.pubnub.com/assets/images/keyset-config-1cd001be92eefbb7214a8b7d4e522d61.png)

To learn more about the available configuration options and the defaults, click the feature name.

### Webhook configuration

Features that send events (Presence, App Context, Mobile Push Notifications, and Message Persistence) can forward events to configurable URLs. Create an event listener and attach a [webhook](https://www.pubnub.com/docs/serverless/events-and-actions/actions/create-webhook-action) action in [Events & Actions](https://www.pubnub.com/docs/serverless/events-and-actions/overview).

:::warning Legacy webhook configuration
Webhooks used to be configurable on the **Keysets** page in Admin Portal. If you're on a [paid plan](https://www.pubnub.com/pricing/), we will migrate your existing webhooks for you.
If you're on a free plan, refer to our [webhook migration guide](https://www.pubnub.com/docs/general/resources/migration-guides/legacy-webhooks-migration-guide).
:::

## Manage secrets

The **Manage secrets** section allows you to create, update, and delete digital credentials for authentication purposes. Once created, you can use the secrets in [Functions](https://www.pubnub.com/docs/serverless/functions/overview).

:::note Roles with access
Only members with the **Keyset Admin**, **Account Owner**, and **Account Admin** [roles](https://www.pubnub.com/docs/portal/my-account#members-and-roles) can work with secrets.
:::

![Manage secrets section with table and Create secret button](https://www.pubnub.com/assets/images/secrets-ba17061479ed7f66880be22ef6553132.png)

You can add new entries to the vault by clicking the **Create secret** button, or, if you already have some entries, by clicking **Edit** in the top-right corner of the secrets table. Each new secret must have a name and a value.

:::note Secret value visibility
For security, secret values aren't shown after creation.
:::

The secrets table displays all entries by default. You can use the search box at the top of the table to filter through the results.

### Secret key rotation

If you are on a [paid](https://www.pubnub.com/pricing/) plan, you can rotate secret keys on your keyset.

This feature helps you maintain a secure, compliant environment with PubNub services (such as [Access Manager](https://www.pubnub.com/docs/general/security/access-control)) by automating key management and avoiding reuse of compromised keys. Each rotation is recorded in the [Audit Log](https://www.pubnub.com/docs/portal/audit-log).

You can stage up to five secret keys with future expiry dates (including the current key).

You can view active and expired secret keys under the current key in the Admin Portal.

![Secret key rotation panel with active and expired keys](https://www.pubnub.com/assets/images/secret-key-rotation-d2504599acbe722307ac7ed30443b4d8.png)

To set an expiry date for a secret key, select **Rotate** and use the date picker to choose the expiry time.

![Date picker to set secret key expiry date](https://www.pubnub.com/assets/images/date-picker-2dcf578d844df025dcf90aa9b408d9aa.png)

## Terms in this document

* **PubNub** - PubNub is a real-time messaging platform that provides APIs and SDKs for building scalable applications. It handles the complex infrastructure of real-time communication, including: Message delivery and persistence, Presence detection, Access control, Push notifications, File sharing, Serverless processing with Functions and Events & Actions, Analytics and monitoring with BizOps Workspace, AI-powered insights with Illuminate.
