WPThumbs
Themes Plugins By purpose By industry Best-of lists Fix it guides
Free Plugin by Lester Chan v2.0.1

WP-PostViews

Enables you to display how many times a post/page had been viewed.

WP-PostViews

The facts

Rating
4.4★ from 65
Active installs
100k+
Price
Free
Last updated
24 Aug 2026
Added
Feb 2006
Requires WP
6.8
Tested up to
WP 7.1
Requires PHP
8.2
Downloads
3,473,703

Our analysis

AI-assisted

WP-PostViews is a WordPress plugin that counts how many times each post, page, or custom post type has been viewed. It allows you to display this count using a shortcode or template tag, and offers customisation options for how the count is shown. The count is stored as post meta, enabling sorting and querying like other post data.

You can choose who is counted in the views—everyone, guests only, or logged-in users—and exclude known bots. The plugin also includes features for displaying the most and least viewed posts, and integrates with the REST API and WP-Stats plugin for additional functionality.

Best for: This plugin is suitable for bloggers and website owners looking to track and display post views.

What it does well

  • Counts views for posts, pages, and custom post types
  • Customisable display via shortcode or template tag
  • Options to control who is counted in views
  • Includes widget for displaying most and least viewed posts
  • Integrates with WP-Stats for enhanced analytics

Where it falls short

  • Limited information on user interface and setup process
  • No details on support or documentation availability

Verdict

WP-PostViews provides a straightforward solution for tracking post views, with flexible display options. It may be useful for those wanting to enhance their site's analytics.

From the developer

Lester Chan's own description of WP-PostViews, lightly tidied.

WP-PostViews counts how many times each post, page or custom post type has been read and gives you somewhere to show the number. The count is kept as post meta, so it sorts, queries and exports like anything else WordPress stores about a post.

Features

  • A view count on any post, page or custom post type, printed by a template tag or by the [views] shortcode.
  • Two templates you edit yourself, with tokens for the count, the title, the date, the excerpt, the thumbnail, the author and more.
  • Choose who is counted — everyone, guests only or logged in users only — and leave known robots out.
  • Template tags and a widget for the most and least viewed posts, optionally within a category or a tag.
  • A sortable Views column on the post and page list tables.
  • The count on the REST API as a views field, and an AJAX counting path for sites behind a page cache.
  • A section on the WP-Stats page when that plugin is installed.

Donations

I spent most of my free time creating, updating, maintaining and supporting these plugins, if you really love my plugins and could spare me a couple of bucks, I will really appreciate it. If not feel free to use it without any obligations.

Usage

The simplest way, and the only one that works in a block theme without editing template files, is the shortcode. Put it in the post or page whose count you want shown:

  • [views] shows the count for the post it appears in.
  • [views id="1"] shows the count for post 1, wherever you put it.

To show the count on every post automatically, a classic theme calls the template tag from index.php, archive.php, single.php or page.php, anywhere inside the loop:

<?php if ( function_exists( 'the_views' ) ) { the_views(); } ?>

The settings live at WP-Admin -> Settings -> WP-PostViews, on two tabs. Settings is where you choose who gets counted and whether WP-Stats is offered a Views section; Templates is where you edit the markup a count is rendered with.

Where the count appears is decided by where your theme calls the_views() or where you put the shortcode. To hide it somewhere in particular, answer the wp_postviews_should_display filter:

add_filter( 'wp_postviews_should_display', function ( $show ) {
    return ! is_archive() && ! is_search();
} );

Showing The View Count In A Block

One block is available in the editor, under Widgets:

  • Post Views — the view count, rendered with the template from the Templates tab. Leave Post ID at zero to show the count of the post the block is in, which is what an empty [views] does, or set it to another post’s ID to show that post’s count instead.

Read the full description on the official page →

Tagged as

Alternatives

Other plugins for custom content structures.

Ad Inserter

Manage Google AdSense ads, banners, ad rotation, sticky widgets, AMP ads, ads.txt, tracking, header and footer...

Free 300k+ installs 4.9★ (2,428)
Advanced Custom Fields

ACF helps customize WordPress with powerful, professional and intuitive fields. Proudly powering over 2 millio...

Free 2M+ installs 4.5★ (1,438)
Simple Custom Post Order

Easily reorder posts, pages, custom post types, and taxonomies with intuitive drag-and-drop sorting in the Wor...

Free 300k+ installs 4.8★ (569)
WP Activity Log

The #1 user-rated activity log plugin for event logging, activity monitoring and change tracking.

Free 300k+ installs 4.7★ (488)
Custom Post Type UI

Admin UI for creating custom content types like post types and taxonomies

Free 1M+ installs 4.6★ (276)