WP-PostRatings
Adds an AJAX rating system for your WordPress site's content.
Sichere Auswahl
Yes — WP-PostRatings is a safe, well-maintained plugin to use in 2026. It runs on 20K+ sites, is rated 4.4/5 and was last updated 3 months ago, and scores 87/100 on our health check.
- Bewährt auf 20.000 aktiven Standorten
- Getestet mit dem neuesten WordPress (7.1)
- Momentum — downloads up 23% vs the previous 30 days
- Benötigt PHP 8.2 oder neuer
Wie stapelt es sich?
Side-by-side bei Installationen, Updates, Bewertungen und SupportTägliche Downloads
Download-Spitzen folgen normalerweise einer neuen Version - jede Website, die automatisch aktualisiert wird, gilt als Download.
Ranglisten
Where WP-PostRatings stands todayWordPress.org Ranglisten suchen
Live-Position in der Plugin-Suche, Top 100| Stichwort | Position |
|---|---|
| ajax | #55 |
| Post | >100 |
| rating | #39 |
| ratings | #35 |
| vote | #9 |
Versionsübernahme
Anteil aktiver Sites pro Release.
Bewertungsaufschlüsselung
★★★★★★★★★★ 4.4 from 178 reviews
About WP-PostRatings
From the official readme · v2.0.2Beschreibung
WP-PostRatings adds a rating control to any post, page or custom post type. Visitors pick a value, the vote is posted in the background, and the result appears in its place without a page load.
Merkmale
- Ten rating shapes, drawn with CSS rather than shipped as images, so they stay sharp at any size and cost no HTTP requests — numbers among them, for a scale whose points are read rather than counted.
- A scale, or a two-way up/down control, with the rated and unrated colours as settings.
- Template tags and a shortcode for the highest rated, most rated, lowest rated and highest scoring posts, optionally within a category, a tag or a time range.
- A rating log with sortable columns, filters, bulk delete and Screen Options.
- Google rich snippet markup for the post and its aggregate rating.
- A sidebar widget, and 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.
Verwendung
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 you want rated:
[ratings]rates the post it appears in.[ratings id="1"]shows the rating for post 1, wherever you put it.[ratings id="1" results="true"]shows post 1’s result without letting anyone vote from there.
To put ratings on every post automatically, a classic theme can call the template tag from single.php, archive.php or index.php, anywhere inside the loop:
<?php the_ratings(); ?>
The settings live at WP-Admin -> Ratings -> Settings, which has a Settings tab and a Templates tab.
Showing A Rating In A Block
A Ratings block is available in the editor, under Widgets. Two settings in the sidebar:
- Post ID — leave it at zero to rate the post the block sits in, which is what an empty
[ratings]does, or give an id to show another post’s rating wherever you put the block. - Show the result only — displays the rating without offering to change it, for putting a post’s score somewhere it should not be voted from. This is what
results="true"does.
It renders on the server, so the preview in the editor is the real rating rather than an approximation, and changing your shape, colours or templates updates every post showing it without re-saving anything. The preview is deliberately not clickable: rating from the editor would record a real vote.
The shortcode still works and is not going anywhere. [ratings], [ratings id="1"] and [ratings id="1" results="true"] behave exactly as they always have, and a post already containing one needs no change. The block calls the same code the shortcode calls, so the two render identically — use whichever suits the post.
WP-CLI
wp postratings list
wp postratings list --limit=50 --format=json
wp postratings get 42
wp postratings delete 42 --yes
wp postratings delete --all --what=logs
A rating lives in two places — the running totals each post displays, and a row per vote in the log. --what chooses which to clear: logs, data or both, and both is the default.
REST API
GET /wp-json/postratings/v1/post/<id>
POST /wp-json/postratings/v1/post/<id>/rate
Reading is public, because a rating is public. Rating takes the same wp_postratings_<id>-nonce the rendered control already carries, passed as a nonce parameter, and is subject to the same eligibility and repeat-rating settings as rating through the page.
Each response carries the rendered markup as well as the numbers, because your templates and your chosen shape decide what a rating looks like.
A refusal answers 403, not 400 — a rating already cast, a rating off the end of the scale, a bad nonce. 400 is kept for a parameter this plugin never had a chance to look at. A post that does not exist answers 404, and so does one you are not allowed to rate — a draft belonging to somebody else answers exactly as a deleted post does, rather than confirming it is there.
These routes are an addition. The admin-ajax.php wp_postratings action is unchanged and still supported.
Installation
- Installieren und aktivieren Sie das Plugin.
- Go to
WP-Admin -> Ratings -> Settingsand choose the shape, the scale and who is allowed to rate. - Show the control: type
[ratings]into a post, add the Ratings block, or callthe_ratings()from your theme.
Änderungsprotokoll
Requires WordPress 6.8 and PHP 8.2. Settings migrate on the first admin page load. The fifteen postratings_* rows, plus the shared stats_display and stats_mostlimit rows, are folded into one wp_postratings_options row, and postratings_db_version and postratings_options_version become a single wp_postratings_version. Code reading the old rows directly will find them gone. Update all seven WP-Stats plugins together. WP-Stats, WP-PostRatings, WP-Polls, WP-EMail, WP-PostViews, WP-DownloadManager and WP-DraftsForFriends shared two unprefixed rows, stats_display and stats_mostlimit. Each now keeps its own copy and deletes the shared rows once it has read them, so whichever you update first takes them from the rest. A missing row means "show", so a block you had switched off may reappear — switch it off again under Ratings -> Settings -> WP-Stats, where the setting and the entries-per-list figure now live. The settings screen is at Ratings -> Settings, with Settings and Templates as two tabs of it. admin.php?page=wp-postratings-options is now admin.php?page=wp-postratings-settings. The capability is still manage_ratings. Two Google rich snippet settings became one, defaulting to No. "Enable Google Rich Snippets?" and "Enable Ratings In Rich Snippets?" are now Show ratings in Google results?. The old markup declared schema.org/Article, and Google shows ratings only for Book, Course, Event, Local Business, Movie, Organization, Product, Recipe, Software App and a few subtypes — so on an ordinary post it never produced a rich result. If you filtered wp_postratings_schema_itemtype to a supported type, you were getting a real rich result, and it stops until you select that same type in the new setting. The filter still runs and still has the last word. Pick a type only if the content genuinely is that thing: marking a blog post as a Product to collect stars is spammy structured markup, and it costs a manual action. Rating images are now CSS shapes. The 16 image sets are 10 shapes; whichever set you had is mapped to the matching shape automatically. A custom image folder falls back to stars — the FAQ shows how to register a shape instead, which survives updates. Custom CSS needs updating. Every class and id is slug-prefixed now: .post-ratings is now .wp-postratings .post-ratings-image is gone; there is no `` any more the wrapper id is wp-postratings-123, not post-ratings-123 the stylesheet is css/wp-postratings.css, not postratings-css.css, and there is no -rtl variant Colour, size, spacing and hover colour are CSS custom properties, so most overrides become a one-line change. See the FAQ. Renamed with no shim left behind: the rate_post action is now wp_postratings_rate_post, with the same three arguments RATINGS_IMG_EXT is now WP_POSTRATINGS_IMG_EXT every class is WP_PostRatings_* rather than Postratings_* The template tags — the_ratings(), get_highest_rated(), get_most_rated() and the rest — and the twenty-two wp_postratings_* filters are unchanged. "Header That Contains The IP" now reads only the first valid address rather than storing the whole chain. Rating logs recorded through it before the update no longer match, so a few visitors may be able to rate once more. Clear the field unless you are behind a reverse proxy. Custom JavaScript. The markup carries no inline onmouseover or onclick handlers and there is no jQuery. Code calling current_rating() or rate_post() in the browser must be rewritten against the delegated listener in js/wp-postratings.js.
2.0.2
- NEW: A
wp_postratings_needs_assetsfilter, for code that renders a rating where WP-PostRatings cannot see it coming. 2.0.0 loads the stylesheet and the rating script only where it finds the ratings widget, a[ratings]shortcode, the block, or a rating rendering during the page itself. Rating markup fetched overadmin-ajax.phpor the REST API into a page that shows no rating of its own is none of those, and got neither file — leaving a rating that cannot vote and, since every shape is a CSS mask, draws as a bare row of radio buttons. Returning true from the filter is how such a page asks for them.
2.0.1
- NEW: Numbers is a rating shape again. It was the one pre-2.0.0 image set with no shape to land on — every other set was a glyph repeated once per point, and a CSS mask cannot differ per position — so it was parked on circles, and a site that had chosen numbers came back from the update to five identical circles with no way to get the digits back. Numbers is now a shape of its own, offered under Scale beside the others, and the
numbersimage set maps onto it. It draws as one continuous bar of cells rather than five floating glyphs, and takes its colours from the Rated and Not rated settings like every other shape, so it has no palette of its own. Sites already migrated onto circles can simply select it; nothing about their ratings changes, only what those ratings are drawn with - NEW:
wp_postratings_shapesaccepts'type' => 'numeric', for a scale drawn as its own positions. Such a shape needs no path, and the digits follow the site’s locale - FIXED: The shape picker grouped its rows by the shape’s exact type rather than by the control it is — a scale, or a pair of opposing actions. Any shape whose type was neither of the two words the radios offer landed in a group no radio could select and stayed hidden
- NEW: A Settings link on the plugin’s row on the Plugins screen
- FIXED: A visitor who may not rate is now told the actual reason. One template covers every refusal and it carried a single sentence written for one of them, so a site set to Guests Only refused a logged-in member and then told them to become a registered member — the one thing that would not have helped. The three reasons now read separately, and the sentence comes from a new
%RATINGS_PERMISSION%variable. The update puts that variable into the stored Ratings No Permission Text in place of the old sentence, so an existing site gets the corrected wording without touching its settings — and a site that had reworded that sentence keeps its own wording untouched. - FIXED: The numbers shape drew its box two different ways — the sides as a border on the container, the top and bottom as inset shadows on the bar inside it. Same colour, but the sides fell on the page background while the top and bottom fell on the bar’s own tint, so the sides came out at several times the contrast and the box read as two heavy verticals with nothing joining them. All four edges are now drawn together, and the bar is no longer two pixels narrower than the box around it.
- FIXED: Only one request at a time runs the outstanding upgrade. Until the plugin records itself as current the check runs on every front-end request, and the part of it that adds the log table’s indexes reads the table’s index list and then alters the table — so on a busy site two requests could both find an index missing and both try to add it, the second waiting on the first for as long as the alter took.
- CHANGED: A stylesheet named
wp-postratings.cssin the parent theme now overrides the plugin’s copy too; a child theme’s copy still wins over both - FIXED: The comment author ratings display, which a theme opts into with the
wp_postratings_display_comment_author_ratingsfilter, showed nothing at all on a block theme. It read the comment from a global that only a classic theme’s comment loop sets; a block theme renders each comment through the comment template block, which passes the comment along instead and leaves that global empty. The comment now comes from where thecomment_textfilter puts it, so the display works on both. - FIXED: The comment author ratings display, which is off unless a theme opts in, still cost its query: every page with a loop fetched every rating the displayed post had ever received, then threw them away. Sites that have not opted in no longer pay it — one query fewer on every page, and on a heavily rated post it was not a small one.
- CHANGED: The stylesheet and script load only on pages that actually render a rating — from the template tags, the shortcode, the block, the widget, the statistics lists or the comment author display. Pages with no rating on them no longer carry either file; pages with one get both — in the head where the page’s content already shows a rating coming, in the footer for the renders the head cannot see.
- FIXED: Nothing unpublished could be rated by anybody, including the people who wrote it. 2.0.0 required a post to be publicly viewable before it would accept a rating — which stops a stranger rating your drafts, and was the point — but it never asked who was rating, so a site whose editors rate their own drafts, pending or private posts got
Invalid Post IDon every vote. A post you can already read is now ratable whether or not the public can see it, and the message no longer blames the post ID, which is rarely what is wrong with it. - NEW:
wp_postratings_is_ratablefilters whether a given post may be rated at all, for sites whose answer is neither of the two above. - CHANGED: The REST error code for a post that may not be rated is
wp_postratings_not_ratablerather thanwp_postratings_no_such_post. The status is still 404, deliberately: a 403 would tell a stranger that the draft exists.
2.0.0
- FIXED: Any post ID could be rated, not only a published one. A visitor who was never signed in could seed
ratings_users,ratings_scoreandratings_averageonto a draft, a pending, a private or a trashed post — so it arrived already rated on the day it was published — and the unpublished title was copied into the log table, where the Logs screen then displayed it. On a site that had put%POST_TITLE%or%POST_CONTENT%into the text template, the reply returned unpublished content directly. Both the AJAX action and the REST route now require a post that is actually publicly viewable - NEW: A
wp postratingsWP-CLI command —list,getanddelete, with--what=logs|data|both. - NEW: A
postratings/v1REST API for reading a post’s rating and casting one. Theadmin-ajax.phpwp_postratingsaction is unchanged and still supported. - NEW: A Ratings block for the editor, with the post id and a results-only toggle in the sidebar. It renders on the server through the same code the shortcode does, so the editor preview is the real rating. The
[ratings]shortcode is unchanged and still supported — the block is an addition beside it, nothing needs migrating, and posts already holding a shortcode need no edit. - BREAKING: Requires WordPress 6.8 and PHP 8.2.
- BREAKING: The rating images are gone. All 16 image sets and their 121 GIF and PNG files are replaced by 10 shapes drawn with CSS, so ratings are sharp on every screen and cost no HTTP requests. Your chosen set is migrated automatically to the matching shape: stars, stars_crystal, stars_dark, stars_png and stars_flat_png all become
star, thumbs becomesthumb, and so on. If you added your own folder toimages/it will fall back to stars; see the FAQ for how to register a custom shape properly, which unlike the old folder survives an update. - BREAKING: The rating markup has changed completely. A scale is now a group of radio buttons and an up/down is a pair of buttons, so the control announces itself correctly to screen readers and works from the keyboard. Every class and element id is now prefixed with the plugin slug:
.post-ratingsis.wp-postratings,.post-ratings-imageno longer exists at all, and the wrapper id iswp-postratings-123rather thanpost-ratings-123. Colour, size and spacing are CSS custom properties, which is usually a one-line replacement; see the FAQ. - BREAKING: The vote images no longer carry inline
onmouseover/onclickattributes; hovering and clicking are handled by one delegated listener. Custom CSS or JavaScript that targeted those inline handlers, or that calledcurrent_rating()orrate_post()directly, needs updating. - BREAKING: The
rate_postaction is renamedwp_postratings_rate_postand the old name is gone, with no deprecation shim. Its three arguments are unchanged. - BREAKING: Every class is renamed to
WP_PostRatings_*, and the plugin’s own classes are no longer calledPostratings_*.RATINGS_IMG_EXTis nowWP_POSTRATINGS_IMG_EXT. - BREAKING: The settings screen moved to
WP-Admin -> Ratings -> Settings, atadmin.php?page=wp-postratings-settings. Settings and Templates are the two tabs of that one page rather than two menu entries. - BREAKING: The option rows are renamed. The fifteen
postratings_*rows become onewp_postratings_options, and the two separate version markers become onewp_postratings_version. Your settings are migrated automatically on the first load after the update. - BREAKING: The shared, unprefixed
stats_displayandstats_mostlimitoption rows are no longer read. WP-Stats integration is now two settings of this plugin’s own, on the Settings tab, and WP-Stats asks each plugin for its section through thewp_stats_sectionsfilter rather than reading anybody’s options. Update all seven WP-Stats-aware plugins together; see the Upgrade Notice. - BREAKING: If you set “Header That Contains The IP” (for Cloudflare, a load balancer or any reverse proxy), that header is now parsed as the forwarded-for chain it is, and only the first valid address in it is used. Previously the whole header value was stored, so a visitor could rate repeatedly just by appending another address to it. Existing rating logs recorded through such a header will no longer match, so some visitors may be able to rate once more. Leave the field blank unless you are actually behind a proxy. See the FAQ.
- BREAKING: “Ratings Logging Method” is now “Check For Repeat Votes”, and it no longer decides whether anything is logged. It never did anything but choose what a returning visitor is matched against, and the two readings pointed opposite ways: a site that picked “Do Not Log” or “Logged By Cookie” got no ratings log, no rows on the logs screen and no WP-Stats figures, which is not what either choice sounds like. Every vote is now recorded whatever this is set to. The choices read “Do Not Check”, “Check By Cookie”, “Check By IP Address”, “Check By Cookie And IP Address” and “Check By Username”; the stored numbers are unchanged, so your setting means what it always meant. The option key inside
wp_postratings_optionsischeck_methodrather thanlogging_method, migrated automatically. - BREAKING: The
wp_postratings_always_logfilter is gone. It asked for exactly the behaviour above, which is now the default, and a filter that forces the default does nothing. Sites that would rather not keep the record have the opposite filter instead: return false fromwp_postratings_log_ratingand no row is written. The post’s own score and vote count are post meta and are updated either way. - BREAKING: The stylesheet is now
wp-postratings.css, notpostratings-css.css, and there is no separate RTL stylesheet. If your theme ships its ownpostratings-css.cssoverride it will no longer be picked up; rename it, or better, use the colour setting and the CSS custom properties instead. - NEW: Rewritten as classes under
includes/, so the plugin now works installed under any directory name. - NEW: Settings moved to the WordPress Settings API, with the options and templates screens merged into one tabbed page.
- NEW: The rating log is now a standard WordPress list table, with sortable columns, bulk delete, a search box and Screen Options.
- NEW: The scripts are vanilla JavaScript; the jQuery dependency is gone, and hovering the stars is pure CSS, so nothing runs on mouse move at all.
- NEW: Rating colours are a setting, per rating rather than per site: each row of the rating table has its own rated and not-rated colour, with a Reset to default beside them. This replaces the old colour variants of the image sets, where changing colour meant choosing a different set of files.
- NEW:
wp_postratings_shapeslets you register your own rating shape. - NEW:
WP_POSTRATINGS_TRUST_PROXYand thewp_postratings_trust_proxyfilter opt into the usual reverse-proxy headers without naming one. “Header That Contains The IP” stays the narrow answer — exactly the one header your proxy sets — and still wins when both are given; the constant is the broad one, meaning “try the seven headers proxies commonly use”. WP-Email, WP-Polls, WP-Ban and WP-UserOnline already worked this way; WP-PostRatings was the one that did not. - NEW:
wp_postratings_capabilityfilters the capability the plugin’s screens require, which is stillmanage_ratings. - NEW: The stylesheet honours
prefers-color-scheme: dark,prefers-contrast: moreandprefers-reduced-motion: reduce. - CHANGED: Ratings display a true percentage instead of being rounded to the nearest half image, so an average of 3.7 out of 5 now fills 74% of the stars rather than showing three and a half.
- CHANGED:
RATINGS_IMG_EXTandwp_postratings_image_extensionno longer choose anything; there are no image files left to have an extension. Thewp_postratings_ratings_image_altfilter stays, but it now sets the rating’s accessible label rather than an image’s alt and title text. - FIXED: The plugin requested an admin stylesheet that had been an empty file since 2020.
- FIXED: The per-post lock file was never released, so one was left behind in the server’s temporary directory on every single rating.
- FIXED: Uninstalling on a multisite network stopped after the first 100 sites, leaving the options and the rating table behind on every site after that.
- FIXED: Activating network-wide also stopped after 100 sites.
- FIXED: A rating outside the configured scale was recorded as a vote worth nothing, and warned on PHP 8.
- FIXED: Comment author ratings never matched by IP, so they had been silently broken since ratings began being stored hashed.
- FIXED: The “numbers” rating image set could not be saved; it reported success and reverted to stars.
- FIXED: Post titles containing an apostrophe were stored in the log with a stray backslash.
- FIXED: The rating log always claimed to be sorted “Descending” whichever order was chosen.
- FIXED: Deleting all rating data left every post’s cache holding the values that had just been removed.
- FIXED: Numerous PHP 8 warnings on the admin screens and in an unconfigured widget.
- NEW: When an up/down post has no verdict to show, it shows you your own vote instead. A tie points nowhere, so rating a post down and landing on one drew a blank pair that looked exactly like the control you had just clicked — as though the vote had not been recorded. Your vote is the only direction that can honestly be attributed at that point, so it takes the shape and the label reads “You rated this down”. A post that does have a verdict keeps showing it: one that is 500 to 3 in favour must not read as a thumbs down to the single visitor who disagreed. Your vote comes from the “already rated” cookie, or from the rating log when the repeat-vote check is by username. It is deliberately never matched by IP address: behind a proxy or a mobile network many visitors share one address, so that would tell somebody who had never voted that they had
- FIXED: An up/down rating with no verdict was drawn as a vote down. Zero is not a direction: a post nobody has rated, and a post with as many down votes as up, both average zero, and both showed a lit thumbs down. They now show the pair unlit. This also fixes what a site sees after switching from a scale to an up/down control — an up/down vote is worth -1 or +1, so a score off a scale of stars is far too large to be one, and reading it as a direction showed every previously rated post as a thumbs up that no amount of voting down could shift. Such a post now shows the unlit pair until its up/down votes outweigh its history, and the vote count and score are reported exactly as stored throughout
- FIXED: On a dark colour scheme the unrated shapes stayed the light grey chosen for a light page, and glared. The dark default is a custom property set on the container
the_ratings()adds — but the widget, and the shortcode and block when asked for results only, print the rating without that container, so nothing they drew ever inherited it. The same was true of the high-contrast default
Screenshots
Für Entwickler
Ist das dein Plugin? Zeigen Sie die Zahlen.
Fügen Sie Ihrer Website, Docs oder GitHub Readme ein Live-Badge hinzu. Es wird von selbst aktualisiert - kein Konto erforderlich.
Best WP-PostRatings alternatives
All ajax plugins →Fragen und Antworten
WP-PostRatings: quick answers
Gerade Antworten, gezogen von Live WordPress.org Daten.
Quelle: WordPress.org
Is WP-PostRatings free?
Yes. WP-PostRatings is free to download and use from the official WordPress.org plugin directory.
Is WP-PostRatings safe to use in 2026?
Yes — WP-PostRatings is a safe, well-maintained plugin to use in 2026. It runs on 20K+ sites, is rated 4.4/5 and was last updated 3 months ago, and scores 87/100 on our health check.
How many websites use WP-PostRatings?
WP-PostRatings is active on 20K+ WordPress websites and has been downloaded 2,301,561 times since it launched in February 2006. It was downloaded 4,169 times in the last 30 days.
Does WP-PostRatings work with WordPress 7.1?
Yes. The developer has tested WP-PostRatings up to WordPress 7.1.5, the latest release. It requires WordPress 6.8 or newer.
What PHP version does WP-PostRatings need?
WP-PostRatings requires PHP 8.2 or higher. Most hosts run PHP 8.x today, so it works on any modern WordPress hosting.
When was WP-PostRatings last updated?
The latest version, 2.0.2, was released on September 1, 2026 (3 months ago).
Who makes WP-PostRatings?
WP-PostRatings is developed and maintained by Lester Chan.
What are the best alternatives to WP-PostRatings?
The most popular alternatives to WP-PostRatings are zipaddr-jp (50K+ installs), SearchWP Live Ajax Search (40K+ installs) and WP-Polls (40K+ installs).
Angetrieben von PageForge
Eine Vorlage und eine Tabelle. Eine echte Seite für jede Suche.
PageForge Verwandelt jede Zeile eines CSV in eine WordPress-Seite mit eigenem Titel, URL, SEO Felder und Schema entworfen. Kostenlos auf WordPress.org.
- CSV und XLSX, plus Google Sheets auf Beruf und Unternehmen
- seinen eigenen Titel, URL, SEO Felder und Schema für jede Seite
- Arbeitet mit dem Blockeditor, Elementor, Divi und Avada
- Kostenlos auf WordPress.org, keine Kreditkarte
