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

# Custom user agent

> Customize the user agent to detect app traffic.

## Default user agent strings in Median

By default, Median appends a platform-specific identifier to the end of the native device user agent:

* **iOS**: `MedianIOS/1.0 median`
* **Android**: `MedianAndroid/1.0 median`

This modification enables your server to detect and respond differently to requests coming from your Median-powered app.

> [!NOTE]
>
> **Legacy GoNative user agent strings**
>
> GoNative.io was rebranded to Median in September 2023. Apps that were originally built on the legacy GoNative.io platform may still use the legacy user agent strings:
>
> * iOS app: `GoNativeIOS/1.0 gonative`
> * Android app: `GoNativeAndroid/1.0 gonative`
>
> These legacy strings exist only for backward compatibility with pre-rebrand builds. Any app built or rebuilt on Median uses the current `MedianIOS` and `MedianAndroid` strings above. To confirm the exact user agent used in your app, open the **Web Overrides** tab in App Studio or use our [deviceInfo debugging function](https://docs.median.co/docs/device-info.md).

## Using a custom user agent

You can fully customize the user agent by selecting the Custom option in your app configuration and entering your preferred string. This gives you complete control over how your app identifies itself to your backend.

## Detecting Median in JavaScript

You can also detect whether a request originates from your app directly in your website’s JavaScript using `navigator.userAgent`. For example:

```javascript JavaScript theme={null}
if (navigator.userAgent.indexOf('median') > -1) {
  // App-specific logic here
}
```


## Related topics

- [Custom CSS](https://docs.median.co/docs/custom-css.md)
- [Website overrides overview](https://docs.median.co/docs/website-overrides-overview.md)
- [Lightning Web Components and the Median JavaScript Bridge](https://docs.median.co/docs/salesforce-lwc-median.md)


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