Title: Plugin is bloating the DB
Last modified: September 22, 2023

---

# Plugin is bloating the DB

 *  [Kay](https://wordpress.org/support/users/kaystyled/)
 * (@kaystyled)
 * [2 years, 8 months ago](https://wordpress.org/support/topic/plugin-is-bloating-the-db/)
 * Hi there!
 * I’m working on a client’s site. They’ve had the Post Views plugin on their site
   for quite some time now (a few years actually). In the process of working on 
   a migration of the site—going from a staging environment to production, I noticed
   it was taking too long for the site to fully migrate. Through investigation with
   my site host, we identified that the issue is associated with this plugin. The
   site is currently migrating approximately 40million database rows and this plugin
   accounts for more than 30million database rows associated it’s created.
 * Essentially, this plugin is bloating the DB. I’m looking to understand 1) how
   to fix that and 2) how to address it further.
 * Can you please assist?
 * Thanks,
 * Kay
    -  This topic was modified 2 years, 8 months ago by [Kay](https://wordpress.org/support/users/kaystyled/).

Viewing 1 replies (of 1 total)

 *  Plugin Author [dFactory](https://wordpress.org/support/users/dfactory/)
 * (@dfactory)
 * [2 years, 8 months ago](https://wordpress.org/support/topic/plugin-is-bloating-the-db/#post-17105989)
 * Hey,
 * There are two things that you have to take into account regarding the DB – number
   of records and the size it takes. I’m pretty sure these 30M PVC records is much
   smaller then remaining 10M of other data. What is limited in hosting providers
   is the size of data you can keep, not the number of entries. Apart from that 
   these records don’t play any role in you DB queries. Unless you make complex 
   queries with post views it’s impact on site speed is literally none.
 * Now, probably 99% of these records come from the daily post views data, that 
   user might not necesserilly need. What is most useful usually is the aggregated,
   total data. We have taken that into account while development of the plugin and
   made it available to control from the UI with a click of a button. The Reset 
   Data Interval option allows you to define for how long daily, individal views
   records will be stored. By default it is not removed, but it can be set to for
   example 3 months or a month and a DB table with the views will be kept in as 
   minimal state as possible.
 * Hope this helps.

Viewing 1 replies (of 1 total)

The topic ‘Plugin is bloating the DB’ is closed to new replies.

 * ![](https://ps.w.org/post-views-counter/assets/icon-256x256.png?rev=2973820)
 * [Post Views Counter](https://wordpress.org/plugins/post-views-counter/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/post-views-counter/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/post-views-counter/)
 * [Active Topics](https://wordpress.org/support/plugin/post-views-counter/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/post-views-counter/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/post-views-counter/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [dFactory](https://wordpress.org/support/users/dfactory/)
 * Last activity: [2 years, 8 months ago](https://wordpress.org/support/topic/plugin-is-bloating-the-db/#post-17105989)
 * Status: not resolved