Simple 5 star Rating using Pure CSS

Today, We want to share with you Simple 5 star Rating using Pure CSS.In this post we will show you How To Create a Simple Star Rating with CSS, hear for Simple 5-star Rating System with CSS and Html Radios we will give you demo and example for implement.In this post, we will learn about A simple star rating system using vanilla JS, CSS and HTML with an example.

Simple 5 star Rating using Pure CSS

There are the Following The simple About Simple 5 star Rating using Pure CSS Full Information With Example and source code.

Read Also:  VueJS Bar and Star Rating Component and demo

As I will cover this Post with live Working example to develop Setting stars color on hover in star rating system, so the turn a number into star rating display using jquery and css for this example is following below.

Pure CSS Star Rating Example

simple HTML with Pure CSS Star Rating System With Color Change


<!DOCTYPE html>

	<meta charset='UTF-8'>
	<title>Pure CSS Star Rating System With Color Change</title>
			width: auto;
			margin:6% 0 0 35%;
		.css3-rating-stars label::before{
			display: inline-block;
		.css3-rating-stars label:hover,
		.css3-rating-stars label:hover ~ label{
			color: #06befb;
		.css3-rating-stars *{
			margin: 0;
			padding: 0;
		.css3-rating-stars input{
			display: none;
			unicode-bidi: bidi-override;
			direction: rtl;
		.css3-rating-stars label{
			color: #ccc;
		.css3-rating-stars label::before{
			content: "05";
			width: 48px;
			line-height: 25px;
			text-align: center;
			font-size: 52px;
			cursor: pointer;
		.css3-rating-stars input:checked ~ label{
			color: #f5b301;
			opacity: .50;
			-webkit-pointer-events: none;
			-moz-pointer-events: none;
			pointer-events: none;

<div class="star-plugin">
	<p>Simple CSS3 Star rating system demo with tutorial</p>
			<div class="css3-rating-stars">
					<input type="radio" name="star-rating-1" id="star-rating-1-0" value="5" />
					<label for="star-rating-1-0"></label>
					<input type="radio" name="star-rating-1" id="star-rating-1-1" value="4" />
					<label for="star-rating-1-1"></label>
					<input type="radio" name="star-rating-1" id="star-rating-1-2" value="3" />
					<label for="star-rating-1-2"></label>
					<input type="radio" name="star-rating-1" id="star-rating-1-3" value="2" />
					<label for="star-rating-1-3"></label>
					<input type="radio" name="star-rating-1" id="star-rating-1-4"  value="1" />
					<label for="star-rating-1-4"></label>

Web Programming Tutorials Example with Demo

Read :

Read Also:  5 Star Product Rating Review Widget in CSS


You can also read about AngularJS, ASP.NET, VueJs, PHP.

I hope you get an idea about Simple 5 star Rating using Pure CSS.
I would like to have feedback on my blog.
Your valuable feedback, question, or comments about this article are always welcome.
If you enjoyed and liked this post, don’t forget to share.

Related FAQ

Here are some more FAQ related to this Article:

  1. Read Also:  Hello World with ASP.NET Core - Install ASP.NET Core steps
  2. Read Also:  Simple CSS Star Rating plugin
  3. Read Also:  Rating Stars with simple jQuery
  4. Read Also:  How to use foreach object keys and values in Node Js?
  5. Read Also:  PayPal Payment Gateway with PHP MySQL Database
  6. Read Also:  how to create database in mongodb?
  7. Read Also:  Codeigniter Helpers Example
  8. Read Also:  How to upgrade php 5.6 to php 7 in XAMPP on Windows?
  9. Read Also:  PHP Laravel 6 SweetAlert jQuery Ajax Delete Rows Example
  10. Read Also:  Bootstrap 5 star rating Example