# How to bulk delete contacts

{% hint style="info" %}
Note: You will need to have data flows enabled for this in your workspace
{% endhint %}

This article covers how you can bulk delete contacts in Bird using a file upload.

* Go to **Settings > AI and Automation > Data flows.**
* Create a new data flow with following source and destination

1. **Source:** CSV Upload
2. **Destination:** Delete contact

<figure><img src="https://3861485111-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU9kiDiTGVD8kkbnKKyEn%2Fuploads%2FrgvD1ZHjCwcK9Vmqm2fu%2FBulk%20delete%20contacts%20create%20a%20new%20data%20flow.png?alt=media&#x26;token=c7b5e12e-3bf4-4f29-9b0d-94dc41b587e2" alt="" width="375"><figcaption></figcaption></figure>

* Once created, go to **Configuration > Source** (left-hand panel)
* you can upload a csv containing either email, phone or contact IDs to be deleted
* You can export contacts from a list or segment or the contacts page, and upload here in the data flow.&#x20;

<figure><img src="https://3861485111-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU9kiDiTGVD8kkbnKKyEn%2Fuploads%2FKJVC4xIKDIkw8wNFMOG2%2FScreenshot%202025-09-11%20at%205.17.08%E2%80%AFPM.png?alt=media&#x26;token=081f4756-389d-470d-b4d4-6c193b7f76f3" alt=""><figcaption></figcaption></figure>

* Click on **Save Configuration** after upload
* Move to **Transformation** section and click on **Open transformation editor**

<figure><img src="https://3861485111-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU9kiDiTGVD8kkbnKKyEn%2Fuploads%2FYs2wa5XdnorHu8fjq8oq%2FScreenshot%202025-09-11%20at%205.15.44%E2%80%AFPM.png?alt=media&#x26;token=d1abb951-d4a2-4bf7-989e-2b6554e3aae7" alt=""><figcaption></figcaption></figure>

* Then, click on **JSONata** under Transformation

<figure><img src="https://3861485111-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU9kiDiTGVD8kkbnKKyEn%2Fuploads%2FcA3ntt3fUHUyG17Hnamc%2FScreenshot%202025-09-11%20at%205.16.20%E2%80%AFPM.png?alt=media&#x26;token=b85db964-bdd1-4217-ad08-ee8db320fb28" alt=""><figcaption></figcaption></figure>

#### Adding JSONata

* You will need to add the following in JSONATA expression if your key identifier is phonenumber:

```jsonata
{
 "identifierKey": "phonenumber",
 "identifierValue": $.Phone
}
```

* If your key identifier is email, then use below

```
{
 "identifierKey": "emailaddress",
 "identifierValue": $.Email
}
```

* You can also delete contacts based on simply Contact ID irrespective of any identifier, in this case you would need to change the column name on csv to **Id** and use below:

```
{
 "contactId": $.Id
}
```

Once done click on **Save.**

**Enable and Run the data flow**

* Click on **Enabled** and then click on **Run Now**
* You can **Edit data flow** to upload more files under Source and then again click on **Save configuration > Run Now**.

<figure><img src="https://3861485111-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FU9kiDiTGVD8kkbnKKyEn%2Fuploads%2FdImyA00SXTM6hlMTg2qP%2FScreenshot%202025-09-11%20at%205.17.34%E2%80%AFPM.png?alt=media&#x26;token=c50c1497-b589-413b-86ee-97498fbfe002" alt=""><figcaption></figcaption></figure>
