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

# Alias event

> Reference for the alias event that the Web SDK sends when your game opens your website. It makes the browser and the game install count as one player.

The `alias` event records that your game opened your website with a cross-domain link. Manalens then links the browser's anonymous ID to the game's, so reports count the browser and the game install as one player, without `identify`. The browser keeps its own anonymous ID. It is a `track` event with `channel` `web`.

## When it is sent

1. Your game makes a link with `get_cross_domain_url()` ([Godot](https://docs.manalens.dev/sdks/godot.md#open-your-website-from-the-game)) or `GetCrossDomainUrl()` ([Unity](https://docs.manalens.dev/sdks/unity.md#open-your-website-from-the-game), [Unreal](https://docs.manalens.dev/sdks/unreal.md#open-your-website-from-the-game)). A browser game on another domain uses `getCrossDomainUrl()` ([Web SDK](https://docs.manalens.dev/sdks/web.md#a-browser-game-on-another-domain)). The link has `mn_aid=<anonymous ID>`.
2. The [Web SDK](https://docs.manalens.dev/sdks/web.md#players-who-come-from-your-game) on your website reads the parameter, removes it from the address bar, and sends one `alias` event. No setup is needed.

* In consent mode, the event waits for `setConsent(true)`. It is dropped after `optOut()`, `reset()` or `setConsent(false)`.
* It is not sent on an excluded page. It is not sent when the game's anonymous ID is the browser's own ID (a game on your own domain already shares it).

## Properties

| Property | Type | Description |
| - | - | - |
| `previous_id` | String | The anonymous ID of the game install that made the link |

Manalens keeps `previous_id` only on a `web` event with an `anonymous_id`, when `previous_id` is a UUID that differs from the event's own ID. Otherwise it removes the property and stores the rest of the event, and no link is made.

## Sample payload

```json theme={null}
{
  "type": "track",
  "event": "alias",
  "message_id": "d4e5f6a7-b8c9-4d0e-8f1a-2b3c4d5e6f70",
  "channel": "web",
  "version": "0.14.0",
  "original_timestamp": "2026-11-09T11:00:05.000Z",
  "anonymous_id": "8c1d2e3f-4a5b-4c6d-9e7f-0a1b2c3d4e5f",
  "session_id": "1762686000000",
  "context": {
    "page": { "path": "/buy", "title": "Buy Star Forge", "url": "https://example.com/buy" },
    "referrer": "",
    "locale": "en-US"
  },
  "properties": {
    "previous_id": "3f0c5c1e-8a8e-4c1b-9d7e-2b1f4e6a9c10"
  }
}
```

See [one player on the website and in the game](https://docs.manalens.dev/guides/identify-users.md#one-player-on-the-website-and-in-the-game) and [identity resolution](https://docs.manalens.dev/features/identity-resolution.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.