Surprisingly, the kind of confectioners sugar used in buttercream does make a difference! Buttercream recipes should not have a gritty or grainy texture. If they do, it's likely the result of the confectioners sugar. We’ve had great results with Dominos confectioners sugar over the years.  Some brands of confectioners sugar don’t work as well with buttercream frosting recipes.   If a package doesn’t say pure cane sugar, it contains beet sugar which is more likely to give you a grainy outcome. However, we’ve noticed that sometimes even brands that say “Pure Cane Sugar” will result in a grainy consistency. The anti-caking agent used in the sugar could also be the culprit. It’s hard to know without a little experimenting to find the brand that gives a smooth, creamy result every time. We use Dominos or US Sugar (from Costco) and never have grainy buttercream. I'm sure there are other brands that work well also, but these are our go-to.