App Instance ID


The App Instance ID is the unique identifier of the app within the website. The process of associating an app with a website is called provisioning, and it happens when the app is first added to the website.

How Does It Work?

When a user adds an app to his website, the Wix platform generates a new App Instance ID. It is guaranteed to be unique, fixed to a single website, and shared by all of the app endpoints (that is, all of your app components will get the same App Instance ID).

The App Instance ID is persistent inside a website. It will keep its value if the user decides to delete the app and add it again.

The Wix platform delivers the App Instance ID to all of the app endpoints using the dedicated instance query parameter. Learn more about this parameter here.

How Should I Use It?

The App Instance ID should be the identifier of the website, and it should be used to link the content of the app to a specific website.

If your app includes App Settings, the App Settings iframe opens with the same App Instance ID as the app iframe and identifies the active user.

If your app requires persistent data storage, the collection of data, or any other use of a unique ID, the App Instance ID is the bridge (foreign key) between your app and the Wix website.

To get the instanceId of your app in a given site, use the Wix.Utils.getInstanceId SDK method.

Was this page helpful?

What can we do to improve it?

What did you like about it?