# How to delete a database in phpMyAdmin

> Step-by-step guide to dropping a database or a single table in phpMyAdmin, whether you're on XAMPP, WAMP, or a remote host.

Published: 2019-08-03T11:57:51.000Z
Updated: 2026-04-24T10:00:00.000Z
Author: Shameem Reza
Category: Development
Canonical: https://shameemreza.com/how-to-delete-database-in-phpmyadmin/

---

import Tldr from '../../components/Tldr.astro';

Dropping a database in phpMyAdmin is straightforward once you know where the option lives. The button isn't exactly hidden, but it's in two different places depending on which screen you start from, which is why people usually think the feature is missing on their first try.

<Tldr>
  To delete a database, open phpMyAdmin, click **Databases** in the top menu, tick the database you want to drop, and click **Drop** at the bottom. Or, open the database from the left sidebar, go to the **Operations** tab, and click **Drop the database (DROP)**. To delete a single table instead, open the database and click the red **Drop** button next to the table name. Always take a backup first. The action is permanent.

</Tldr>

## Before you delete anything

Dropping a database is permanent. There's no "undo" and no recycle bin. Before you click the button:

- Take a full backup. In phpMyAdmin, select the database, go to the **Export** tab, and save the `.sql` file somewhere safe.
- Make sure you've picked the right database. Names can be similar, and production and local copies sometimes share a naming pattern.
- If this is a live site, make sure nothing is still pointing at it.

## Delete a database from phpMyAdmin (XAMPP or WAMP)

If you're running XAMPP or WAMP, start Apache and MySQL from the control panel, then open `http://localhost/phpmyadmin` in your browser. The dashboard looks like this:

![phpMyAdmin dashboard on localhost](/uploads/phpmyadmin-1-1024x447.png)

Click **Databases** in the top menu to see the list of every database on the server.

![List of databases in phpMyAdmin](/uploads/phpmyadmin-db-list-1-1024x789.png)

From here, there are two ways to drop one.

### Option 1: from the Databases list

Tick the checkbox next to the database (or databases, you can select more than one), then scroll down and click **Drop**. Confirm the prompt and it's gone.

![Dropping a database from the Databases list](/uploads/phpmyadmin-delete-db-1024x680.png)

### Option 2: from the Operations tab

Click the database name in the left sidebar to open it. A new row of tabs appears at the top. Click **Operations**, scroll down, and you'll see **Drop the database (DROP)** in red. Click it, confirm, and the database is removed.

![Dropping a database from the Operations tab](/uploads/different-way-to-delete-1-1024x511.png)

![Confirmation prompt before dropping the database](/uploads/final-db-delete.png)

Both routes do exactly the same thing. Use whichever one matches where you already are in the UI.

## Delete a single table from a database

Sometimes you don't want to drop the whole database, just one table. Open the database from the left sidebar and you'll see every table listed on the right.

![Database with tables listed](/uploads/database-list-1.png)

To drop one table, click the red **Drop** button next to it.

![Drop button next to a single table](/uploads/delete-table-in-database-1024x571.png)

To drop several at once, tick the checkbox next to each table you want to remove, then use the **With selected** dropdown at the bottom of the list. Pick **Drop** to delete the tables entirely, or **Empty** to keep the table structure and clear the rows.

![Bulk drop from the With selected dropdown](/uploads/database-drop-1-1024x414.png)

That's the whole thing. The only part that ever catches people out is remembering the backup before you hit **Drop**.
