You can set the message persistence retention time to 1, 7, 30, 90, 180, 365 days or Unlimited.
To change it, log in to your PubNub account and navigate to Message Persistence feature of a given key set.
Free tier users can store messages up to 7 days, whereas clients with our Starter Plan can have their retention time set to 180 days. Retention time above 180 days requires Pro Plan.
If you wish to learn more about Pro Plan, contact our sales department by using this form.
NOTE: If you are on Limited retention time and switch to Unlimited (or vice versa), you will not be able to retrieve messages from the former database.
However, you can request dual database read by contacting support.
Switching within Limited range still allows fetching messages that were stored before the change.