What does the wp_options table store?
The wp_options table holds one row for each named setting. WordPress reads every row marked for autoload before it builds the page. A heavy autoload set adds time to every request, including pages that never use that plugin.
- siteurl, home, and the active theme names
- active_plugins, the list of plugins that are turned on
- cron, which stores scheduled tasks
- transient rows, which are timed cache
- settings left behind after a plugin folder is removed
WordPress 6.6 still loads the old value yes. It also loads on, auto, and auto-on. Values off, no, and auto-off stay in the table until some code asks for that option.
A page builder you already removed, including WPBakery, can leave rows named for that plugin. Those rows are leftover settings. They are not a content table, and they are not a reason to edit posts.
Which rows must you leave alone?
Delete a row only when you know its option_name and you have an export. The rows below keep the site on the network, the theme on the page, and plugins running. Removing them is not a cleanup.
| option_name | What it does | If you delete it |
|---|---|---|
| siteurl and home | The addresses WordPress uses for the site. | The site can redirect in a loop or lose its URL. |
| active_plugins | The list of plugins that are on. | Every plugin turns off at once. |
| template and stylesheet | The active theme. | The front end can render blank. |
| cron | The schedule for background tasks. | Updates, scheduled posts, and timed jobs stop. |
| wp_user_roles | Role names and what each role may do. | Administrators can lose access. The prefix matches the table, so shop_options means shop_user_roles. |
rewrite_rules can be rebuilt by opening Settings, then Permalinks, and saving. Do not delete by a short fragment such as a plugin brand or the letters icl. That match can hit a row you still need.
How do you run the cleanup in phpMyAdmin?
Open cPanel, then phpMyAdmin, and select the WordPress database. The table list on the left shows the real prefix. If you see shop_options instead of wp_options, use shop_options in every statement below.
Size of what WordPress loads on each request:
SELECT ROUND(SUM(LENGTH(option_value))/1024, 1) AS autoload_kb, COUNT(*) AS row_count FROM wp_options WHERE autoload IN ('yes','on','auto','auto-on');
Heaviest autoloaded names:
SELECT option_name, autoload, ROUND(LENGTH(option_value)/1024, 1) AS kb FROM wp_options WHERE autoload IN ('yes','on','auto','auto-on') ORDER BY LENGTH(option_value) DESC LIMIT 20;
Expired transient timeouts, so you can read them before any delete:
SELECT option_name, FROM_UNIXTIME(option_value) AS expired_at FROM wp_options WHERE option_name LIKE '\_transient\_timeout\_%' AND option_value < UNIX_TIMESTAMP() LIMIT 50;
Delete those expired pairs only. The value row starts with _transient_ and the timeout row starts with _transient_timeout_. For rows that start with _site_transient_, use the same join with _site_transient_timeout_ and take the name from character 17.
DELETE a, b FROM wp_options a INNER JOIN wp_options b ON b.option_name = CONCAT('_transient_timeout_', SUBSTRING(a.option_name, 12)) WHERE a.option_name LIKE '\_transient\_%' AND a.option_name NOT LIKE '\_transient\_timeout\_%' AND b.option_value < UNIX_TIMESTAMP();
One leftover row, after you have checked the name:
DELETE FROM wp_options WHERE option_name = 'the_exact_name' LIMIT 1;

- In phpMyAdmin, select the WordPress database, open Export, and save the SQL file. Stop if the file does not download. Import this file if a later step breaks the site.
- Run the size query. If the grid is not one row with autoload_kb and row_count, the prefix is wrong. Under about 1 MB, skip the deletes and read the last section. Over that, run the heavy-name query and keep the list.
- Run the expired-timeout SELECT. Every option_name should start with _transient_timeout_. If you are cleaning network transients, those names start with _site_transient_timeout_. If any name is something else, do not run the DELETE.
- Run the DELETE that joins each expired timeout to its value row. Run the size query again. Open the homepage. A normal page, not a database error, means you can continue. A value row with no timeout partner is left for the next step.
- Pick one heavy option_name. Search wp-content/plugins for that string. Delete the row only when that plugin folder is gone and the name matches exactly. Use the single-row DELETE. Reload the homepage and wp-admin.
- If either screen shows a database error, Import the SQL export and stop. If both screens load, repeat the previous step for the next name. Do not delete a second row in the same statement.
If you will not run SQL, use a database plugin that deletes expired transients and shows the rows first. Do not confirm a task that deletes every option or every transient.
Clearing cached pages is separate from these rows. Use the steps to clear the WordPress cache after the table work, or the old HTML can still look slow.
How do you clean the same rows with WP-CLI?
Use this only when the host gives you a shell. Change to the directory that contains wp-config.php. Run wp option get home. The printed address must be this site. If it is a different site, stop.
Delete expired transients, then list the largest autoloaded values:
wp transient delete --expired
wp db query "SELECT option_name, LENGTH(option_value) AS bytes FROM $(wp db prefix)options WHERE autoload IN ('yes','on','auto','auto-on') ORDER BY bytes DESC LIMIT 20"
Read the names the same way as in phpMyAdmin. Delete one confirmed leftover with wp option delete and the exact name. The command should confirm the delete. Load the homepage before you delete another name.
On a multisite network, add --network only to the transient command, and only for the network cache. Each site still has its own options table. wp db prefix prints the prefix of the site you selected.
When is the table not why the site is slow?
If autoload_kb is already under about 1 MB, more deletes will not make the homepage faster. Look at the page cache first, then at overhead phpMyAdmin shows on wp_options after a large delete. That overhead is recovered when you repair and optimize the MySQL database.
If the autoload total is already small and PHP still takes most of the request, the account needs more database room than this cleanup can free. WordPress hosting is where that plan comparison belongs.
The cleanup steps do not add a hosting charge by themselves. Email support@webji.services for a quote before you pay. The inbox is staffed 24/7 in Hindi and English. A move between hosts is a migration, and free migration is subject to terms and approval.
Frequently Asked Questions
What is the wp_options table in WordPress?
The wp_options table stores one row per named setting, including the site URL, active plugins, the theme, cron, and transients. WordPress loads every autoloaded row on each request.
Why is my wp_options table so large?
Expired transients and settings from plugins you removed are the usual cause. The file on disk can stay large after those rows are gone until the table is optimized. The slowdown on every page comes from the autoloaded total, not from the file size alone.
How do I clean autoloaded options in WordPress?
Export the database. Count rows whose autoload value is yes, on, auto, or auto-on. Delete expired transients, then one leftover option at a time. Leave siteurl, home, active_plugins, template, stylesheet, and cron in place.
Is it safe to delete transients?
Expired transients are safe to delete, and WordPress rebuilds them on the next request that needs them. Leave timeouts that are still in the future if you want that cache kept. Do not delete every row whose name merely contains the word transient.
How do I find which plugins bloat wp_options?
Sort autoloaded rows by the length of option_value. Match a heavy option_name to a folder under wp-content/plugins. If that folder is gone and the name matches exactly, the row is a leftover from that plugin.
Can WP-CLI clean the wp_options table?
Yes, when the host provides WP-CLI. From the folder that contains wp-config.php, run wp transient delete --expired. Delete one confirmed leftover with wp option delete and the exact option name, then reload the site.
What if the table is not named wp_options?
Use the name you see in phpMyAdmin. A table named shop_options means every statement uses shop_options, and the roles row is shop_user_roles.

