ClientStorage

Browser storage for plugin data that persists across sessions.

ClientStorage interface

Browser storage for plugin data that persists across sessions.

Signature:

interface ClientStorage

Remarks

  • Client storage allows you to store data on the user's browser. Unlike PluginData, data stored here is not saved with the animation file - it's local to the user's browser only.

  • Store values like booleans, numbers, strings, dates, objects, arrays, regexps, undefined, or null.

  • The total amount of data you can save per plugin is limited to 5 MB.

  • This data is specific to your plugin ID. It will be inaccessible if your plugin ID changes.

  • Other plugins cannot access this data. However, you should avoid storing sensitive data here. It is possible for users to inspect this data through browser developer tools.

  • As this data is stored on the user's browser, it might be cleared if the user clears their browser data.

Example

Store and retrieve user preferences:

await creator.clientStorage.set("theme", "dark");

// Retrieve preferences
const theme = await creator.clientStorage.get("theme"); // "dark"

Methods

Method

Description

clear()

Clears all client storage data for this plugin.

delete(key)

Deletes a value from client storage.

get(key)

Retrieves a value from client storage.

keys()

Gets all storage keys for this plugin.

set(key, value)

Stores a value in client storage.

usedQuota()

Gets the current data quota usage (in bytes) for this plugin.

Last updated: August 5, 2026 at 11:47 AMEdit this page