# Connection

> Set the port Xerlock looks for Metro on, or let your app report it.

**Connection** sets where Xerlock finds Metro, which the Console, Network, Debugger, React and Navigation panels reach your app through. The host is always `localhost`.

![The Connection section with the Metro port and the switch to use the port the app reports](/_astro/settings-connection-light.BdmSJpGB_NhClc.webp)![The Connection section with the Metro port and the switch to use the port the app reports](/_astro/settings-connection-dark.C5p9_r0x_8vxFR.webp)

The Connection section with the Metro port and the switch to use the port the app reports

## Metro port

**Metro port** defaults to `8081` and takes a whole number from 1024 to 65535. Press Enter or click away to apply it. Anything outside that range reverts to the previous port.

## Using the port your app reports

With **Use the port reported by the app** on, which is the default, Xerlock uses the port your app reports through the SDK instead of **Metro port**. Metro on another port, such as `npx expo start --port 8082`, is then found once your app connects. Turn it off to always use **Metro port**.

The line under the switch says which port is used:

| Line                                                | Meaning                                                                         |
| --------------------------------------------------- | ------------------------------------------------------------------------------- |
| **No port reported yet. …**                         | No app is connected through the SDK, so **Metro port** is used                  |
| **The connected app reports port …**                | Xerlock uses the port your app reports                                          |
| **The connected app doesn’t report its port, so …** | Your app’s `@xerlock/client` is too old to report it. Update it or set the port |

## Limits and Troubleshooting

* **No Metro found on port …** in the Connection panel: Metro isn’t running, or runs on another port. Set **Metro port** to the port Metro prints when it starts.
* The SDK’s own port, `9340`, can’t be changed. See [SDK port](/docs/desktop/connection/#sdk-port).
