---
myst:
html_meta:
"description lang=en": "Kasm Workspaces uninstall instructions."
"keywords": "Kasm, Uninstall, Server, Setup"
"property=og:locale": "en_US"
---
```{title} Uninstall
```
# Uninstall
- Stop All Kasm services.
```bash
sudo /opt/kasm/current/bin/stop
```
- Remove any Kasm session containers.
```bash
sudo docker rm -f $(sudo docker container ls -qa --filter="label=kasm.kasmid")
```
- Remove Kasm service containers.
```bash
export KASM_UID=$(id kasm -u)
export KASM_GID=$(id kasm -g)
sudo -E docker compose -f /opt/kasm/current/docker/docker-compose.yaml rm
```
- Remove the Kasm docker network.
```bash
sudo docker network rm kasm_default_network
```
- Remove the Kasm database docker volume.
```{parsed-literal}
sudo docker volume rm kasm_db_{{ release }}
```
- Remove the Kasm docker images.
```{parsed-literal}
sudo docker rmi redis:5-alpine
sudo docker rmi postgres:9.5-alpine
sudo docker rmi kasmweb/nginx:latest
sudo docker rmi kasmweb/share:{{ release }}
sudo docker rmi kasmweb/agent:{{ release }}
sudo docker rmi kasmweb/manager:{{ release }}
sudo docker rmi kasmweb/api:{{ release }}
sudo docker rmi $(sudo docker images --filter "label=com.kasmweb.image=true" -q)
```
- Remove the Kasm installation directory structure.
```bash
sudo rm -rf /opt/kasm/
```
- Remove the Kasm User Accounts.
```bash
sudo deluser kasm_db
sudo deluser kasm
```