> ## Documentation Index
> Fetch the complete documentation index at: https://docs.upstackdata.com/llms.txt
> Use this file to discover all available pages before exploring further.

# login Event

> Track when a user logs into their account

Fires when a user logs into their account. This helps track returning user engagement and can be used to build audience segments of active customers.

<Note>
  **Shopify:** Manual implementation required. Not automatically tracked.
</Note>

## JavaScript

```javascript theme={null}
window._upstack('track', 'login', {
  method: 'email'
});
```

## Properties

| Property | Type   | Required | Description                                                      |
| -------- | ------ | -------- | ---------------------------------------------------------------- |
| method   | string | No       | Login method (`'email'`, `'google'`, `'facebook'`, `'shop_pay'`) |

## When to Fire

* Successful login form submission
* OAuth login completion
* Automatic re-authentication

## Related Events

* [sign\_up](/pixel/events/sign-up) — When new users create accounts
* [complete\_registration](/pixel/events/complete-registration) — For registration flows
