# Manually Connect to a Specific Peer

Use these steps to manually connect your server to a specific [peer](/es-es/docs/concepts/networks-and-servers/peer-protocol) in the XRP Ledger network.

If you want to make sure your server automatically connects to this server on startup and remains connected later, you may want to configure a [peer reservation](/es-es/docs/infrastructure/configuration/peering/use-a-peer-reservation) for that peer.

## Prerequisites

- You must know the IP address of the peer you want to connect to.
- You must know what port the peer you want to connect to uses for the XRP Ledger [peer protocol](/es-es/docs/concepts/networks-and-servers/peer-protocol). The default config file uses port 2459.
- You must have a network connection from your server to the peer. For example, the peer server must [forward the appropriate port through its firewall](/es-es/docs/infrastructure/configuration/peering/forward-ports-for-peering).
- The peer server must have available peer slots. If the peer is already at its maximum number of peers, you can ask the peer server's operator to add a [peer reservation](/es-es/docs/infrastructure/configuration/peering/use-a-peer-reservation) for your server.


## Steps

To connect, use the [connect method](/docs/references/http-websocket-apis/admin-api-methods/peer-management-methods/connect). For example:

WebSocket
```
{
    "command": "connect",
    "ip": "169.54.2.151",
    "port": 2459
}
```

JSON-RPC
```
{
    "method": "connect",
    "params": [
        {
            "ip": "169.54.2.151",
            "port": 2459
        }
    ]
}
```

Commandline
```
xrpld connect 169.54.2.151 2459
```

## See Also

- **Concepts:**
  - [Peer Protocol](/es-es/docs/concepts/networks-and-servers/peer-protocol)
  - [The `xrpld` Server](/es-es/docs/concepts/networks-and-servers)
- **Tutorials:**
  - [Capacity Planning](/es-es/docs/infrastructure/installation/capacity-planning)
  - [Troubleshoot the `xrpld` Server](/es-es/docs/infrastructure/troubleshooting)
- **References:**
  - [connect method](/docs/references/http-websocket-apis/admin-api-methods/peer-management-methods/connect)
  - [peers method](/docs/references/http-websocket-apis/admin-api-methods/peer-management-methods/peers)
  - [print method](/docs/references/http-websocket-apis/admin-api-methods/status-and-debugging-methods/print)
  - [server_info method](/docs/references/http-websocket-apis/public-api-methods/server-info-methods/server_info)