Closing a browser could log you out of a website, but your login session could stay active thanks to session cookies. But session cookies are set to time out or expire after a certain amount of time, so you won’t stay logged in indefinitely.