# How to Destroy Apps in App Platform App Platform is a fully managed Platform-as-a-Service (PaaS) that deploys applications from Git repositories or container images. It automatically builds, deploys, and scales components while handling all underlying infrastructure. Deleting an app permanently and irreversibly destroys the app and its components. If you need to re-deploy the app, you can download the app specification file before deleting the app and [use the saved spec to build the app again](https://docs.digitalocean.com/products/app-platform/how-to/create-apps/index.html.md). ## Destroy an App Using Automation The destroy app CLI command and API endpoint require the app’s ID. You can retrieve a list of your apps and their IDs using the `doctl apps list` command or the [`/v2/apps` endpoint](https://docs.digitalocean.com/reference/api/reference/apps/index.html.md#apps_list) endpoint. ## How to Destroy an App Using the DigitalOcean CLI 1. [Install `doctl`](https://docs.digitalocean.com/reference/doctl/how-to/install/index.html.md), the official DigitalOcean CLI. 2. [Create a personal access token](https://docs.digitalocean.com/reference/api/create-personal-access-token/index.html.md) and save it for use with `doctl`. 3. Use the token to grant `doctl` access to your DigitalOcean account. ```shell doctl auth init ``` 4. Finally, run `doctl apps delete`. Basic usage looks like this, but you can [read the usage docs](https://docs.digitalocean.com/reference/doctl/reference/apps/delete/index.html.md) for more details: ```shell doctl apps delete [flags] ``` The following example deletes an app with the ID `f81d4fae-7dec-11d0-a765-00a0c91e6bf6`: ```shell doctl apps delete f81d4fae-7dec-11d0-a765-00a0c91e6bf6 ``` ## How to Destroy an App Using the DigitalOcean API 1. [Create a personal access token](https://docs.digitalocean.com/reference/api/create-personal-access-token/index.html.md) and save it for use with the API. 2. Send a DELETE request to [`https://api.digitalocean.com/v2/apps/{id}`](https://docs.digitalocean.com/reference/api/reference/apps/index.html.md#apps_delete). ### cURL Using cURL: ```shell curl -X DELETE \ -H "Content-Type: application/json" \ -H "Authorization: Bearer $DIGITALOCEAN_TOKEN" \ "https://api.digitalocean.com/v2/apps/{id}" ``` ### Python Using [PyDo](https://github.com/digitalocean/pydo), the official DigitalOcean API client for Python: ```python import os from pydo import Client client = Client(token=os.environ.get("DIGITALOCEAN_TOKEN")) delete_resp = client.apps.delete(id="b7d64052") ``` ## Destroy an App Using the Control Panel To destroy an app, go to the [**Apps** page](https://cloud.digitalocean.com/apps), select the app you want to destroy, then click the **Settings** tab. At the bottom of the page, click **Destroy**. Enter the app’s name to confirm, then click **Destroy**.