Note: If you build with Wix's Astro integration, you don't need to handle visitor tokens manually because the CLI generates and manages them for you. Otherwise, handle them as described here.
Visitor tokens maintain anonymous visitor sessions, allowing you to track visitor-specific data like shopping cart contents across page visits. Without them, each API call is treated as a new visitor and session data is lost.
When you create a Wix client, visitor tokens are generated automatically. To persist sessions across page loads, store and restore tokens yourself.
For implementation details, see Handle visitors using the JavaScript SDK or Handle visitors using the REST API.
Last updated: 25 June 2026