🔧 Uninstal Manual Langkah demi Langkah

Pas uninstal satu klik nggak bisa pake (misalnya CLI rusak), ikutin step-step di bawah buat manual operation. Urutan penting banget — berhentiin service dulu, terus hapus file, terakhir cabut tools.

Step 1: Stop Gateway Service

Pertama, pastiin gateway service yang jalan di background udah dihenti:

openclaw gateway stop

Kalau openclaw command udah nggak bisa dijalanin, skip step ini, langsung pake system command buat force stop (liat di halaman pembersihan khusus system kamu).

Step 2: Uninstal daemon service

Buka config autostart, supaya service nggak balik lagi setelah restart:

openclaw gateway uninstall

Sama juga, kalau CLI nggak bisa jalan, perlu manual operation — di macOS bersihkan launchd, di Linux bersihkan systemd, di Windows bersihkan scheduled task. Detail ada di halaman khusus masing-masing system.

Step 3: Hapus config dan state data

Semua config file, chat history, running state OpenClaw disimpan di state directory:

rm -rf "${OPENCLAW_STATE_DIR:-$HOME/.openclaw}"

Kalau kamu custom environment variable OPENCLAW_STATE_DIR, perlu cek path aslinya. Default-nya cuma ~/.openclaw.

⚠️ Step ini nggak bisa dibalik! Semua chat history, custom config bakal hilang. Kalau mungkin kamu bakal pakai lagi nanti, backup dulu directory ~/.openclaw lengkap. Rekomendasi backup detail ada di Hal-hal Penting.

Step 4: Hapus file workspace (optional)

Kalau step 3 udah hapus directory .openclaw lengkap, skip step ini. Kalo enggak, bersihkan workspace aja:

rm -rf ~/.openclaw/workspace

Step 5: Cabut CLI tool

Sesuaiin dengan cara kamu instalin OpenClaw dulu, pilih command uninstal yang sesuai:

Instalasi npm

npm rm -g openclaw

Instalasi pnpm

pnpm remove -g openclaw

Instalasi Bun

bun remove -g openclaw

Instalasi Homebrew (macOS)

# Versi CLI
brew uninstall openclaw-cli

# Versi desktop app
brew uninstall --cask openclaw

Instalasi dari source code (git clone)

Kalau instalasi dari source code, pastiin udah rampung service stop dan uninstal step terlebih dulu, terus langsung hapus source directory. Harus berhentiin service dulu sebelum hapus directory, kalo enggak service bisa referensi path yang udah dihapus terus error.

Instalasi multi-Profile

Kalau kamu pake custom Profile (misal satu buat kerja, satu buat personal), setiap Profile punya state directory sendiri, perlu dihapus satu-satu:

# Hapus semua profile directory yang relate sama openclaw
rm -rf ~/.openclaw
rm -rf ~/.openclaw-*
💡 Nggak yakin punya berapa Profile? Jalanin ls -la ~ | grep openclaw buat lihat-lihat.