---
title: SSH Access
description: Connecting to your serverlet over SSH.
---

Unlike typical web hosting, a serverlet supports SSH access, letting you control it just like a local computer.

## Connecting

**Tip:** You need to set a password for the `applet` user before logging in for the first time.

Every serverlet has its own SSH port, available in Administration under the Overview tab. The SSH command structure:

```
ssh {user}@{physical server} -p {serverlet port}
```

Example:

```
ssh applet@serlo.futrou.com -p 10022
```

On Linux or Windows 10 you can use the command line. Otherwise, we recommend the [Putty](https://www.chiark.greenend.org.uk/~sgtatham/putty/latest.html) client.

## Port forwarding

Command structure:

```
ssh -L 127.0.0.1:{local port}:{serverlet's physical server}:{application port} {user}@{physical server} -p {serverlet port}
```

Example:

```
ssh -L 127.0.0.1:80:serlo.futrou.com:80 applet@serlo.futrou.com -p 10022
```

This command exposes the remote application on your local machine.

## Logging in with a public key

1. Generate a private key:

```
ssh-keygen -t ecdsa -b 384 -C {email}
```

2. Upload the public key (`id_ecdsa.pub`) to the `.ssh/` directory in your home directory on the serverlet (for the `applet` user: `/srv/.ssh/`). Options:

```
ssh-copy-id -i {path to public key} {user}@{physical server} -p {serverlet port}
```

Example:

```
ssh-copy-id -i /home/user/.ssh/id_ecdsa.pub applet@serlo.futrou.com -p 10022
```