Logging off users automatically when they close the browser tab or window

Hi Guys,

I want to log off the user when he or she closes the tab or window. I can understand that it can be achieved using Session storage [ import {session} from ‘wix-storage’; ]. If someone can help with the code to achieve this functionality, that would be really helpful.

Hi SKK,

Currently the API doesn’t include functionality that lets you react when the user closes the tab or window. Session storage lets you store information during the browser session but it doesn’t control what happens when the session ends.

-Jeff

Dear Jeff

Is there a feature request for this? Can this be prioritized?

Thanks
Satheesh

https://www.wix.com/corvid/forum/community-feature-request

https://www.wix.com/corvid/forum/community-discussion/logout-on-website-leave-solved-sort-of
https://www.wix.com/corvid/forum/community-discussion/logging-members-out-automatically