Change Product Review star color in Product Grid, Featured Collection

Topic summary

Goal: change product review star color on collection/featured product grids (Shopify Crave, OS 2.0) to yellow.

What worked:

  • Adding CSS in assets/component-rating.css for .rating-star::before with -webkit-text-fill-color: rgb(255,164,28) changed stars to yellow on collection pages.
  • To remove the β€œ5.0/5.0” text, hide p.rating-text.caption via CSS (display: none).

Layout fix:

  • The rating count dropped to a new line; keeping p.rating-count.caption as display: inline-block helped, but the key fix was correcting syntax errors in component-rating.css (removing an extra closing brace in .rating-star::before and fixing β€œinline- block” spacing). After cleanup, alignment worked.

Alternatives/notes:

  • Another suggestion set background: #FFA41C on .rating-star::before. Code snippets were central to the solution; screenshots showed before/after visuals.

Open questions (unresolved):

  • Hiding stars when there are 0 reviews is not feasible with CSS alone (no unique selector; would also hide valid reviews).
  • A user reported all items showing 5 stars after applying code; no fix posted.
  • Request to show blank stars for 0.0 rating remains unanswered.

Status: initial color-change issue resolved; follow-up feature requests remain open.

Summarized with AI on January 8. AI used: gpt-5.

I have already managed to edit the color of product rating stars in the main product page, but unable to change the color in Collections. The theme I’m using is Crave (i believe is Online Store 2.0).

Can anyone help me change the color to yellow in Collection?

@lowowl - can you please share this page link?

Hi,

Please share your store URL and if your store is password protected then also provide password too.

Thank you.

https://www.plantcultureph.com/products/osmocote-controlled-release-fertilizer-14-14-14-40g?keyword=osmocote

https://www.plantcultureph.com/products/osmocote-controlled-release-fertilizer-14-14-14-40g?keyword=osmocote

https://www.plantcultureph.com/collections/fertilizers

@lowowl - please add this css to the very end of your component-rating.css file and check, should look like screenshot below

.rating-star:before {
    -webkit-text-fill-color: rgb(255, 164, 28);}

1 Like

Awesome, that worked. But now there’s a 5.0/5.0 text that popped up. How can i remove this?

Please add below css code in bottom of assets/component-rating.css file

.rating-star::before {
background: #FFA41C;

}

Thank you.

@lowowl - not able to see that text 5.0/5.0

did you remove it?

Can you refresh now, was trying a different code.

@lowowl - try this css, same file as before

p.rating-text.caption {display: none;}

Works!

But now the rating count is dropped one line

@lowowl - please try this

p.rating-count.caption {display: inline-block;}

Implemented, problem persists

@lowowl - where did you add it? can not see it in code file

.rating {
  display: inline-block;
  margin: 0;
}

.product .rating-star {
  --letter-spacing: 0.8;
  --font-size: 1.7;
}

.card-wrapper .rating-star {
  --letter-spacing: 0.7;
  --font-size: 1.4;
}

.rating-star {
  --percent: calc(
    (
        var(--rating) / var(--rating-max) + var(--rating-decimal) *
          var(--font-size) /
          (var(--rating-max) * (var(--letter-spacing) + var(--font-size)))
      ) * 100%
  );
  letter-spacing: calc(var(--letter-spacing) * 1rem);
  font-size: calc(var(--font-size) * 1rem);
  line-height: 1;
  display: inline-block;
  font-family: Times;
  margin: 0;
} 

.rating-star::before {
  content: 'β˜…β˜…β˜…β˜…β˜…';
  background: linear-gradient(
    90deg,
    var(--color-icon) var(--percent),
    rgba(var(--color-foreground), 0.15) var(--percent)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: rgb(255, 164, 28);}
}
.rating-count.caption {display: inline-block;}   
}
.rating-text {
  display: none;
}

.rating-text.caption {display: none;}
}
@media (forced-colors: active) {
  .rating {
    display: none;
  }

  .rating-text {
    display: block;
  }
}

Here’s the entire file

1 Like

@lowowl - this code, it has 2 end brackets β€œ}”, remove one of them and everything will work fine.

.rating-star::before {
  content: 'β˜…β˜…β˜…β˜…β˜…';
  background: linear-gradient(
    90deg,
    var(--color-icon) var(--percent),
    rgba(var(--color-foreground), 0.15) var(--percent)
  );
  -webkit-background-clip: text;
  -webkit-text-fill-color: rgb(255, 164, 28);}
}
1 Like

Hi, would like to ask for help again. I want to remove the stars if there are 0 reviews available for the product. What can I do?

@lowowl - there is no unique class or id to this image, if we add any css to hide it, then it will hide existing reviews too

Worked like magic on my website: vibrantbodymind.co.uk - also love the muted golden color. Thank you!