Ads Top

How to optimize WordPress Database


If you have a WordPress website, it is bound to have a database irrespective of the website being functional or redundant. A WordPress database stores all the data on your website. It includes posts, pages, comments (if any), website, theme and plugin settings, as well as, entries from forms and links if any.

Anything that’s filled with unwanted data hampers its performance. Optimization is, therefore, the key to efficiency and increasing performance. Optimizing your WordPress database ensures that your database size is reduced and the load speed of your website is considerably improved.

In this article, I’ll walk you through how you can optimize WordPress database.

How to Optimize WordPress Database
There are two ways to optimizing your WP database we’ll be covering both:

Method I: Using phpMyAdmin
phpMyAdmin is the most preferred tool to manage your WordPress database. You can find phpMyAdmin in your cPanel under the Databases section.



  • Once you login to phpMyAdmin you can have a look at the size of each table in your database. The size of a table is dependent on the amount of data stored in it. More the data stored, more are the rows in a table which in turn means increased size.
  • Apart from size, there is another column known as Overhead. Overhead is a temporary disk storage space that stores queries. Even though the overhead of a table might increase it hardly affects the performance of the website.
  • The figure below shows the landing page of phpMyAdmin and the extreme right-hand side columns show the ‘Size’ and ‘Overhead’ column.

  • To optimize your database select all the tables in your database by clicking on the checkbox. Next, click on the drop-down menu and select ‘Optimize Table’ and click on ‘Go’


Alternatively, you can also use a SQL command to optimize the tables. The command to be used is:
Query: OPTIMIZE TABLE ‘tablename’
Example: OPTIMIZE TABLE ‘wp_links’
  • After this, the command is executed and you get a message saying your WordPress database has now been optimized.
You can even refer to the official WordPress guide for 

No comments:

Powered by Blogger.