Plugin Directory

Test out the new Plugin Directory and let us know what you think.
!This plugin hasn’t been updated in over 2 years. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.

Better Postviews

An efficient plugin which tracks all single-post views. Easily use the data anywhere in your theme or plugin.

Automatic Installation:

  1. Go to Admin - Plugins - Add New and search for "Better Postviews"
  2. Click on Install
  3. Click on Activate

Manual Installation:

  1. Download better-postviews.zip
  2. Unzip and upload the "better-postviews" folder to your "/wp-content/plugins/" directory
  3. Activate the plugin through the "Plugins" menu in WordPress


This plugin will work out-of-the-box - no configuration is necessary and there is no admin interface. However, it might be necessary to modify a few options (in the code) for a better experience.

  1. To disable tracking but retain the output, change "true" to "false" on line 13 of better-postviews.php
  2. To disable the post column view but retain tracking, change "true" to "false" on line 14 of better-postviews.php
  3. To enable a debug output in comments at the bottom of your sites source code, change "false" to "true" on line 15 of better-postviews.php
  4. To increase or decrease the transient lifetime of the top-one, top-three, and top-five data, change "300" on line 16 to a value of your choice
  5. To use the top-one, top-three, or top-five data elsewhere, simply call better_postviews::get_top_one(), better_postviews::get_top_three(), or better_postviews::get_top_five() and it will return an array of post IDs with element 0 being greatest - prepped and ready for your custom WP_Query!
  6. Will add get_top_five_count or something similar in the future.

Requires: 3.0.1 or higher
Compatible up to: 3.6.1
Last Updated: 3 years ago
Active Installs: 30+


0 out of 5 stars


Got something to say? Need help?


Not enough data

0 people say it works.
0 people say it's broken.