SKR Tips logo SKR TipsWebsite tips that actually work
WordPress

WordPress Database Cleanup for a Busy Gaming Fan Site

Your fan site has run for three years, the admin dashboard takes six seconds to load, and the hosting panel says the database is 900 MB even though you have only 400 posts.

A laptop showing a database admin panel on a desk beside a game controller and notes

Your fan site has run for three years, the admin dashboard takes six seconds to load, and the hosting panel says the database is 900 MB even though you have only 400 posts. That gap is almost always junk: thousands of post revisions, expired transients, spam comments and tables left behind by plugins you deleted long ago. A careful WordPress database cleanup can cut that size by half and make the editor feel fast again, without touching a single patch note or tier list.

I manage the WordPress side of two gaming communities, one for a survival game and one for a card game wiki, and both went through this exact process. Here is what I clean, what I leave alone, and the order that keeps you out of trouble.

Back Up Before Any WordPress Database Cleanup

This step is not optional. Database cleanup deletes rows permanently, and the most common mistake is removing a table that a still active plugin needs. Take a full export first.

  • Use your host's backup tool or phpMyAdmin to export the whole database as a .sql file.
  • Download it to your own computer, not just to the server.
  • Note the date and the size of the file so you can compare afterwards.

Better still, run the cleanup on a copy first. If you already follow the routine in our guide to using a WordPress staging site before big updates, push a fresh copy to staging, clean it, test it for a day, then repeat on live.

What Actually Fills the Database on a Gaming Site

Gaming sites have a specific problem: content gets updated constantly. Every balance patch means editing the same 30 character guides, and every edit saves a revision. On my survival game site, a single "best base locations" guide had 212 stored revisions. Across the site there were over 38,000 revision rows.

Junk typeWhere it livesTypical size on a 3 year old fan site
Post revisionswp_posts and wp_postmeta20,000 to 50,000 rows
Expired transientswp_optionsSeveral thousand rows
Spam and trashed commentswp_comments and wp_commentmetaCan be tens of thousands after a bot wave
Orphaned plugin tablesSeparate tables with old prefixesFrom a few KB to several hundred MB
Autoloaded optionswp_optionsSmall in rows, heavy in load time

Comment spam deserves its own note. Guild and clan sites attract bot traffic, and if your login page has also been a target, our walkthrough on stopping brute force logins on a WordPress guild site pairs well with this cleanup.

A Safe Cleanup Order, Step by Step

  1. Limit future revisions first. Add define('WP_POST_REVISIONS', 5); to wp-config.php. Five is enough to undo a bad edit on a patch guide. Do this before deleting old ones so the pile does not refill.
  2. Delete old revisions. A cleanup plugin can do this in one click. Keep the newest few per post if the plugin allows it.
  3. Empty spam and trash comments. Check the spam queue for a minute first. Real players sometimes land there, especially if they paste build codes full of symbols.
  4. Remove expired transients. These are temporary cached values with a timestamp that has passed. Deleting them is safe; WordPress recreates what it needs.
  5. Find orphaned tables. Look at table names in phpMyAdmin. A table like wp_oldsliderpro_slides from a plugin you removed in 2023 can go. If you cannot identify a table, leave it.
  6. Check autoloaded options. Options with autoload set to yes load on every single page request. Sort by size and look for entries over 100 KB from removed plugins.
  7. Optimise tables last. This reclaims the space freed by all the deletions.

On the card game wiki this order took 25 minutes and the database went from 640 MB to 210 MB. The editor load time dropped from around 5 seconds to under 2.

What I never delete

Some rows look like clutter and are not. User meta for registered members holds forum ranks, guild roles and saved preferences, so leave wp_usermeta alone unless you know exactly which plugin wrote a key. The same goes for anything from your membership, event or leaderboard plugin, even if the table looks huge. A tournament plugin on one of my sites stores every bracket match as a row, and that history is the reason people visit. If a cleanup plugin flags these as "unused", it is guessing. Delete only what you can name, explain and restore.

Why I Do Not Schedule Automatic Cleanups

Most advice tells you to install a cleanup plugin and set it to run weekly. I disagree, at least for community sites with several editors. Automatic schedules run while nobody is watching, and the settings that seemed fine in January may delete something important in June after you add a new plugin that stores data as transients or drafts.

On one site a weekly job set to "delete all auto drafts" wiped a half written tournament recap that a volunteer had been saving as a draft over several evenings. Nobody noticed until she came back to finish it.

My compromise is simple. Limit revisions in wp-config.php so growth stays slow, then do a manual cleanup every three months or after a big plugin change. Pair it with the routine from our WordPress plugin audit for a clan site, since removed plugins are where most orphaned tables come from. A cleanup plugin can stay installed, but deactivated between uses.

How to Check the Cleanup Worked

Do not trust the plugin's own success message. Check three numbers before and after:

  • Total database size in your hosting panel
  • Admin dashboard load time, measured with your browser's network tab on a cold load
  • Time to first byte on a heavy page, such as a big item database or a patch notes archive

Then click through the pages that matter: the homepage, a few top guides, the comment form, the search results page and any custom post types such as character profiles or event listings. If something looks broken, restore the backup and work through the steps one at a time to find the culprit.

FAQ

How often should I clean a WordPress database?

For a gaming site updated several times a week, every three months is plenty once revisions are limited. Clean sooner if you remove a large plugin or recover from a spam comment flood.

Will deleting post revisions hurt my SEO?

No. Search engines only see the published version of a page. Revisions are internal history and never appear on the front end, so removing them has no effect on rankings.

Is it safe to delete transients?

Deleting expired transients is safe because they are past their use date anyway. Deleting all transients is also usually safe, but your site may feel slower for a few minutes while caches rebuild.

What size should a fan site database be?

There is no fixed number, but a site with a few hundred posts and a few thousand comments often sits between 50 and 200 MB after cleanup. If yours is far above that, revisions and orphaned tables are the first places to look.

MO
Matthias Okeke

Matthias ran a clan website and a fan wiki for years before writing about them. He covers the sites gaming communities build, from guides to patch note pages.

More posts by Matthias

More in WordPress

01doorganico 084goad 3hot8 4465456 after5internprogram ahandfulofblessings ahmadpc ahomcybersecurity allodialresources annodex antiquesandperiodcollectibles aotc asianworldkashmir beedlectrics bloggertemplatefree bluefeatheragency bodyweightsolution campaign08blog carfixadvisor catstreetcollective cbstvsports cnfanspurchasing committeeof500yearsofdignityandresistance covertopsdjs cs-kaiyuangame cuestacomunicaciontotal cxoutlet dancebetgame deskgearhub destinyvillastay detectmagazine di33 diamondsteelbuildings donmo dyanadropship emarsysfinance emimattl escapechan eskitarih evautoplay everythingweddings-orlando farmzone feedviewerapp foxstudiosscratch gamevui123 gleasongrade greetingsday hacklabasu haskell iw-kaiyun jagoanproperti jilidskripsi joltbusinessfinance juegodepokergratis juegospucca kaeru-festival latestmehndidesigns lestanzediottaviano litemagazines localcommunityhero lustrsazan mariashebets menswheels newwebstechs1 nikkit ootheday oxigenvpn plurfitness prefetial probudgetcarpetcleaning psychicmrsmartin pyaten qvantor rejoignezlogis rexzbot riselayouts ruchin rwxqsgd5 sakaltime shibiaowang shop-bot strcoding tetapatrium topselller uneplanteartificielle vipertechcr webtech1223411 wo-kygaming yamaha-mekar yeknava yoybuysheets zenunwa yamaha-mekar jilidskripsi ankertoto ankertoto ankertoto ankertoto