# Install on macOS

> Download Cloak Proxy for Mac, signed and notarized by Apple, open it, see what the first launch does, update to a new build, and uninstall everything it made.

Source: https://docs.subcloak.com/cloak-proxy/getting-started/install/

Cloak Proxy is a single Mac app. You download a disk image, drag the app to your Applications folder, and open it. On Linux, see [Install on Linux (beta)](https://docs.subcloak.com/cloak-proxy/getting-started/install-linux/). This page also covers updating to a new build and removing every file, certificate and setting the app creates.

## Check the requirements

| Requirement | Details |
|---|---|
| macOS | macOS 14 Sonoma or later |
| Processor | Apple silicon or Intel. The download is a universal app that runs natively on both. |
| Disk space | The disk image is about 30 MB. |
| Account | None. Cloak Proxy is [free for life](https://docs.subcloak.com/cloak-proxy/getting-started/free-for-life/), with no license key, trial or sign-in. |
| Optional | Xcode, to install the certificate in the [iOS Simulator](https://docs.subcloak.com/cloak-proxy/devices/ios-simulator/) with one click. Android platform tools (`adb`), for one-click [Android](https://docs.subcloak.com/cloak-proxy/devices/android/) setup. |

## Download and install

1. Go to [subcloak.com/apps/cloak-proxy](https://subcloak.com/apps/cloak-proxy).

2. Click **Download for Mac**. Name and email are optional: leave your email only if you want release notes. The download of `Cloak-Proxy.dmg` starts, and the page shows the file's SHA-256.

3. Optional: check the file is the one Subcloak published. In Terminal, run the command below and compare its output with the SHA-256 on the download page. They should match exactly.

   ```bash
   shasum -a 256 ~/Downloads/Cloak-Proxy.dmg
   ```

4. Open `Cloak-Proxy.dmg` from your Downloads folder.

5. In the disk image window, drag **Cloak Proxy** onto the **Applications** shortcut, following the arrow.

6. Eject the disk image. You can delete the `.dmg` file afterwards.

> **Installing on a team's Macs?:**
> (added in Cloak Proxy 0.5.0) From 0.5.0 there's also a signed, notarized installer package, `Cloak-Proxy.pkg`, for device management services. See [Deploy to a team's Macs](https://docs.subcloak.com/cloak-proxy/getting-started/deploy-to-a-team/).

### Install with Homebrew

If you use [Homebrew](https://brew.sh), you can install Cloak Proxy from Subcloak's tap instead. It installs the same notarized app into Applications and puts `cloakctl` on your PATH.

```bash
brew install --cask subcloak/tap/cloak-proxy
```

Update it with `brew upgrade --cask cloak-proxy`. `brew uninstall --cask cloak-proxy` removes the app, and from 0.5.0 also App Capture's network extension if you installed it. (added in Cloak Proxy 0.5.0)

## Open Cloak Proxy the first time

Open **Cloak Proxy** from your Applications folder. It's signed with a Developer ID and notarized by Apple, so it opens like any other app. (added in Cloak Proxy 0.4.2) The first time, macOS asks whether you want to open an app downloaded from the internet: click **Open**.

If you still have 0.4.1 or older, which weren't notarized, see [macOS won't open the app the first time](https://docs.subcloak.com/cloak-proxy/reference/troubleshooting/#macos-wont-open-the-app-the-first-time), or download the current version.

## What happens on the first launch

When Cloak Proxy opens for the first time, it sets itself up on your Mac. Nothing is sent anywhere: the app has no account or activation.

1. **It creates a root certificate.** Cloak Proxy generates its own certificate authority (CA) and private key in `~/Library/Application Support/CloakProxy`. It uses them to decrypt HTTPS for the hosts and apps you choose. See [Root certificate](https://docs.subcloak.com/cloak-proxy/capture/certificate/).

2. **It starts the proxy on port 9090.** The proxy listens on `127.0.0.1:9090`, so only this Mac can use it until you [allow other devices](https://docs.subcloak.com/cloak-proxy/capture/network-settings/).

3. **It turns on the macOS proxy.** Cloak Proxy points the Mac's HTTP and HTTPS proxy settings at itself, so apps and browsers on this Mac send their traffic through it. Your previous proxy settings are saved and come back when you quit. If macOS requires administrator rights to change network settings, it asks for your password. See [Capture macOS traffic](https://docs.subcloak.com/cloak-proxy/capture/macos-traffic/).

4. **It asks you to trust the certificate.** An orange banner reads **Trust the Cloak Proxy certificate to decrypt HTTPS**. Click **Install & Trust…** and confirm with your password. Until you do, Cloak Proxy still records plain HTTP and lists HTTPS connections, but can't show what's inside them.

HTTPS traffic shows as locked tunnels at first. That's expected: Cloak Proxy only decrypts the hosts and apps you turn [SSL Proxying](https://docs.subcloak.com/cloak-proxy/capture/ssl-proxying/) on for. The [Quick start](https://docs.subcloak.com/cloak-proxy/getting-started/quick-start/) walks you through your first decrypted request.

> **Quitting puts your network settings back:**
> While Cloak Proxy captures macOS traffic, every app that follows the system proxy depends on it. Quit with <kbd>⌘</kbd> <kbd>Q</kbd> (closing the window keeps it running) and your previous proxy settings come back. If the app crashes or you force quit it, a small guard process restores them for you. See [The proxy guard](https://docs.subcloak.com/cloak-proxy/capture/macos-traffic/#the-proxy-guard-restores-settings-after-a-crash).

## Update to a new version

(added in Cloak Proxy 0.5.4) From 0.5.4, Cloak Proxy updates itself. Choose **Cloak Proxy › Check for Updates…**: it says **You're up to date**, or shows the new version's release notes with **Install and Relaunch**, **Remind Me Later** and **Skip This Version**. **Install and Relaunch** downloads the update from `download.subcloak.com`, checks it, quits Cloak Proxy the usual way (your proxy settings are put back and capture stops, as with <kbd>⌘</kbd> <kbd>Q</kbd>), installs it and opens the new version. Your certificate, sessions and settings stay as they are. If the app is in a folder you can't write to (installed with the package, for example), macOS asks for an administrator's password.

Before installing, Cloak Proxy checks that the update is signed with Subcloak's update key and that the app in it is signed by Subcloak's Apple Developer ID (team `8JJX52F3NV`). An update that fails either check isn't installed, and the window says why.

- **Installed with Homebrew:** the window shows the new version with **Copy Command**; run `brew upgrade --cask cloak-proxy` so Homebrew keeps track of the version.
- **Managed by your organization:** if a configuration profile turns installing from the app off, the window only says a new version is out: **Your organization installs Cloak Proxy updates on this Mac.**

To be told about new versions without asking, turn on **Check for updates automatically** in **Settings › General › Updates**: Cloak Proxy then checks once a day when it opens. Nothing is downloaded until you choose **Install and Relaunch**. See [Check for updates](https://docs.subcloak.com/cloak-proxy/reference/settings/#check-for-updates).

0.5.3 and earlier don't update themselves: their **Check for Updates…** (added in Cloak Proxy 0.2.2) offers **Download**, **Release Notes** and **Later**, and you update by hand, as below.

### Update by hand

To update 0.5.3 or earlier, download the new build and replace the app. If you installed with Homebrew, quit Cloak Proxy and run `brew upgrade --cask cloak-proxy` instead.

1. Quit Cloak Proxy with <kbd>⌘</kbd> <kbd>Q</kbd>. This restores your macOS proxy settings.

2. Download the latest `Cloak-Proxy.dmg` from [subcloak.com/apps/cloak-proxy](https://subcloak.com/apps/cloak-proxy).

3. Drag **Cloak Proxy** onto **Applications** and choose **Replace** when Finder asks.

4. Open the new copy.

Your settings, rules, root certificate, saved filters, kept traffic and API client workspace live outside the app, so an update keeps all of them. You don't need to trust the certificate again. If you [capture apps that ignore the proxy](https://docs.subcloak.com/cloak-proxy/capture/apps-that-ignore-the-proxy/), Cloak Proxy refreshes its background helper to point at the new copy when it opens. If you use [App Capture](https://docs.subcloak.com/cloak-proxy/capture/capture-apps-that-ignore-the-proxy/), macOS replaces its network extension with the new copy's by itself: there's nothing to approve again, and App Capture keeps its apps.

## Where Cloak Proxy keeps its files

- ~/Library/
  - Application Support/CloakProxy/
    - cloak-proxy-ca.pem the root certificate
    - cloak-proxy-ca-key.pem the root certificate's private key (readable only by you)
    - api-token the token for the local control API, cloakctl and MCP
    - ca-bundle.pem macOS root certificates plus Cloak Proxy's, created when you set up a Terminal
    - autosave.cloaksession captured traffic, only while Keep captured traffic when Cloak Proxy quits is on (readable only by you)
    - Workspace/ the API client workspace, unless you chose another folder
  - Logs/CloakProxy/
    - cloak-proxy.log diagnostics: proxy changes, listener errors, certificate actions
    - cloak-proxy.log.1 to .3 older diagnostics, once the log passed 10 MB
  - Preferences/
    - com.subcloak.cloakproxy.plist settings, debugging tool rules, filter presets, pins
  - LaunchAgents/
    - com.subcloak.cloakproxy.dns-standby.plist only while you capture apps that ignore the proxy
- /etc/resolver/
  - example.com one file per captured domain, only while you capture apps that ignore the proxy

The login keychain also holds the trusted root certificate (named `Cloak Proxy CA (…)`), and, if you used those features, a **Cloak Proxy GitHub token** item for [publishing Gists](https://docs.subcloak.com/cloak-proxy/sessions/publish-to-gist/) and **CloakProxy Vault** items for the API client's [vault](https://docs.subcloak.com/cloak-proxy/api-client/variables-and-environments/).

Captured traffic stays in memory until you [save a session](https://docs.subcloak.com/cloak-proxy/sessions/save-and-open/). It's written to disk on its own only if you turn on **Keep captured traffic when Cloak Proxy quits** in **Settings › General**, which saves it to `~/Library/Application Support/CloakProxy/autosave.cloaksession`.

## Uninstall Cloak Proxy completely

Undo the system changes from inside the app first, while it's still installed. Then delete the app and its files.

> **Back up your API client workspace first:**
> `~/Library/Application Support/CloakProxy/Workspace` holds your collections, environments and specs if you kept the default workspace folder. Copy it somewhere else before you delete the folder in step 6 if you want to keep them.

1. **Remove App Capture's network extension**, if you installed it. (added in Cloak Proxy 0.5.0) Open **Proxy › Device & Runtime Setup… › App Capture**, click **Remove Extension…** and confirm. macOS may ask for your password, or finish at the next restart. Deleting the app doesn't remove the extension. See [Remove App Capture](https://docs.subcloak.com/cloak-proxy/capture/capture-apps-that-ignore-the-proxy/#remove-app-capture).

2. **Stop capturing apps that ignore the proxy.** If the sidebar shows a **Not using the proxy** section with captured apps (a green check mark), click each one and choose **Stop Capturing**. This removes the files in `/etc/resolver` and the background helper. macOS asks for your password.

3. **Remove the root certificate.** Open **Cloak Proxy › Settings… › Certificate** and click **Remove from Keychain**. This removes the trust setting and deletes every Cloak Proxy CA from your login keychain.

4. **Quit Cloak Proxy** with <kbd>⌘</kbd> <kbd>Q</kbd>. Your previous macOS proxy settings come back.

5. **Delete the app.** Drag **Cloak Proxy** from Applications to the Trash.

6. **Delete its files.** In Terminal:

   ```bash title="Terminal"
   rm -rf ~/Library/Application\ Support/CloakProxy
   rm -rf ~/Library/Logs/CloakProxy
   defaults delete com.subcloak.cloakproxy
   ```

7. **Remove keychain items you created.** Open **Keychain Access**, search for `Cloak Proxy` and `CloakProxy`, and delete the **Cloak Proxy GitHub token** and any **CloakProxy Vault** items. Or in Terminal:

   ```bash title="Terminal"
   security delete-generic-password -s com.subcloak.cloakproxy.github
   ```

8. **Remove the extras you set up.** Only if you made them:

   | You set up | Remove it |
   |---|---|
   | `cloakctl` linked into `/usr/local/bin` | `sudo rm /usr/local/bin/cloakctl` |
   | Cloak Proxy as an MCP server in Claude Code | `claude mcp remove cloak-proxy` (or delete the `cloak-proxy` entry from your assistant's MCP config) |
   | TLS key logging | Delete the key log file, by default `~/Desktop/cloak-proxy-sslkeys.log` |
   | The certificate on an iPhone, iPad, simulator or Android device | Remove it on the device. See [Devices](https://docs.subcloak.com/cloak-proxy/devices/overview/). |
   | The proxy on an Android device | In Cloak Proxy's **Android** setup, click **Disconnect Proxy** before you uninstall, or run `adb shell settings put global http_proxy :0` |
   | The proxy on an iPhone or iPad | **Settings › Wi-Fi › ⓘ › Configure Proxy › Off** |

### Clean up after deleting the app

If you already deleted the app without the steps above, remove what's left by hand.

**Proxy settings**

If websites stop loading after Cloak Proxy is gone, the Mac's proxy may still point at `127.0.0.1:9090`. Open **System Settings › Network**, select your connection (for example Wi-Fi), click **Details…**, open **Proxies**, and turn off **Web proxy (HTTP)** and **Secure web proxy (HTTPS)**. Or in Terminal, for each network service:

```bash title="Terminal"
networksetup -setwebproxystate "Wi-Fi" off
networksetup -setsecurewebproxystate "Wi-Fi" off
```

`networksetup -listallnetworkservices` lists your service names.

**Root certificate**

```bash title="Terminal"
security delete-certificate -c "Cloak Proxy CA"
```

Run it again until it reports that the certificate can't be found. You can also search for `Cloak Proxy CA` in **Keychain Access** and delete it there.

**Network extension**

(added in Cloak Proxy 0.5.0) If **System Settings › General › Login Items & Extensions › Network Extensions** still lists Cloak Proxy, or `systemextensionsctl list` shows `com.subcloak.cloakproxy.transparent-proxy`, reinstall Cloak Proxy into Applications and remove the extension from its App Capture page, or run:

```bash title="Terminal"
"/Applications/Cloak Proxy.app/Contents/MacOS/CloakProxy" --remove-network-extension
```

Then delete the app again.

**Captured domains**

Captured domains resolve through Cloak Proxy. Without the app and its helper they stop resolving, so remove the resolver files and the helper:

```bash title="Terminal"
for f in /etc/resolver/*; do
  head -1 "$f" | grep -q '^# Cloak Proxy capture' && sudo rm -f "$f"
done
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder

launchctl bootout gui/$(id -u)/com.subcloak.cloakproxy.dns-standby
rm -f ~/Library/LaunchAgents/com.subcloak.cloakproxy.dns-standby.plist
```

The loop only deletes files whose first line is Cloak Proxy's marker, so resolver files from other tools stay.

## Related

  - [Quick start](https://docs.subcloak.com/cloak-proxy/getting-started/quick-start/): Decrypt your first HTTPS request in five minutes.
  - [Root certificate](https://docs.subcloak.com/cloak-proxy/capture/certificate/): Install, trust, remove and regenerate the certificate.
  - [Capture macOS traffic](https://docs.subcloak.com/cloak-proxy/capture/macos-traffic/): How the system proxy is turned on and restored.
  - [Security and privacy](https://docs.subcloak.com/cloak-proxy/reference/security-and-privacy/): What stays on your Mac and how to remove everything.
