Zainab found a Little Debbie Cosmic Brownie in her lunchbox once and came home asking me to make "the rainbow cookie" — and honestly, I didn't even know where to start. I'd eaten those things as a kid too, but recreating them at home felt like I was attempting something that only worked in a factory. Turns out it's not that complicated at all.
What makes these work is the ganache on top — that's the part that actually makes it feel like a cosmic brownie instead of just a brownie-flavored cookie. The base is dense, fudgy, and chocolatey in the way that a good brownie is, and the glossy chocolate layer on top ties the whole thing together. Don't skip it. I know it adds a step, but it takes maybe five minutes and makes the cookie look like something you'd actually pay $4 for at a bakery.
I make a double batch now because a single batch disappears before the cookies have even fully cooled. Zainab picks off the rainbow chips first (every time, without fail), and my husband will eat four without blinking. If you're baking for a birthday or a party, these are genuinely a good call — they're fun to look at and they hold up well once the ganache sets. I've also tucked them into cookie boxes for gifts around the holidays, and they survive being stacked as long as you put wax paper between layers. If you want something more classic for the holidays, my Soft Gingerbread Cookies with Maple Glaze are great alongside these in a cookie tin.
One thing to set expectations on: don't overbake these. Eight to ten minutes sounds like nothing, but that's the window. Pull them out when the centers still look a little underdone — they finish cooking on the hot pan while they cool down. The first time I made them, I left them in for twelve minutes and they went from fudgy to firm. Still good, just not the gooey texture I was going for.

Why You'll Love This Recipe
- The texture is genuinely fudgy: These aren't cakey brownie cookies — they're dense and chewy in the middle the way a proper brownie should be. Getting that texture in cookie form takes a bit of attention (mainly not overbaking), but once you nail it, it's really satisfying. My husband said after the first batch that they tasted like the inside of a brownie, which is exactly what I was going for.
- The ganache is easy and it makes all the difference: I was nervous about ganache before I tried it, but it's literally just hot cream poured over chocolate chips. You wait two minutes, stir, and it's done. It sets into that glossy, slightly firm top layer that makes these look and taste like something special — not just a regular chocolate cookie.
- Kids love decorating them: The rainbow chip step is the easy part and also the part children find most exciting. Zainab takes this job very seriously. If you're baking with kids, this is a recipe where they can genuinely help without the whole thing going sideways.
- Everything is in your pantry already: Butter, sugar, cocoa powder, eggs, flour — the only thing you might need to track down specifically is rainbow chips or confetti sprinkles, and those show up in the baking aisle at Walmart or Kroger. Nothing exotic here.
- They hold up well for gifting: Once the ganache firms up, these cookies travel surprisingly well. I've packed them into tins between sheets of wax paper and they've arrived looking good. For anyone building a holiday cookie box, these work well alongside something like my Chocolate Gingerbread Mini Cakes — the flavors complement each other nicely.
Ingredients
- 1 cup unsalted butter, softened
- 1 cup granulated sugar
- ½ cup brown sugar
- 2 large eggs
- 1 teaspoon vanilla extract
- 1½ cups all-purpose flour
- ½ cup unsweetened cocoa powder
- 1 teaspoon baking soda
- ½ teaspoon salt
- 1½ cups semisweet chocolate chips
- ½ cup colorful candy-coated chocolate pieces (like M&Ms)
For the Topping:
- ½ cup heavy cream
- 1 cup semisweet chocolate chips
- ½ cup mini rainbow sprinkles
- ¼ cup candy-coated chocolate pieces
Directions
- Preheat the oven: Set your oven to 350°F (175°C) and line two baking sheets with parchment paper. Getting the oven fully up to temperature before the cookies go in matters for getting that set edge with a soft center.
- Make the cookie dough: In a large bowl, beat the softened butter, granulated sugar, and brown sugar together until creamy. Add the eggs one at a time, mixing after each, then stir in the vanilla. In a separate bowl, whisk together the flour, cocoa powder, baking soda, and salt. Gradually add the dry ingredients to the butter mixture and mix until just combined — don't overwork it. Fold in the chocolate chips and candy-coated pieces.
- Shape the cookies: Scoop tablespoon-sized portions of dough and roll them into balls. Place them on the lined baking sheets about 2 inches apart — they spread a little. Flatten each ball slightly with the back of a spoon or just the palm of your hand.
- Bake: Bake for 10–12 minutes, until the edges look set but the centers are still soft. They'll look slightly underdone — that's correct. Let them sit on the hot baking sheet for 5 minutes before moving them to a wire rack. They finish setting during that rest time.
- Make the ganache: While the cookies cool, heat the heavy cream in a small saucepan over medium heat until it's steaming but not boiling. Pour it over 1 cup of chocolate chips in a bowl and let it sit untouched for 2 minutes. Then stir until completely smooth and glossy. If it looks grainy, keep stirring — it will come together.
- Top the cookies: Once the cookies are fully cooled (this matters — warm cookies will make the ganache slide right off), spoon a small amount of ganache onto each one and spread it gently toward the edges with the back of a spoon.
- Add the rainbow chips: Before the ganache sets, scatter rainbow sprinkles and candy-coated pieces over the top. Press them in very lightly. Then let everything sit at room temperature until the ganache firms up — about 20–30 minutes.

Tips for Success
- Don't overbake — seriously: I cannot say this enough. The centers should look underdone when you pull the tray out. I set a timer for 10 minutes and check at that point. If the edges are set and the center still has a slight wobble, they're done. Eight minutes of extra oven time ruined my first batch and I had perfectly round chocolate pucks instead of fudgy cookies.
- Cool completely before adding ganache: This is non-negotiable. I tried to rush it once — the ganache turned into a puddle and slid off the sides. Let the cookies come fully to room temperature. If you're in a warm kitchen, 20 minutes on the rack should do it, but give them a touch test first.
- Heat the cream to steaming, not boiling: Boiling cream can cause the ganache to seize or look grainy. I pull it off the heat as soon as I see steam rising — usually after about 2–3 minutes on medium. If you accidentally let it bubble, let it cool for a minute before pouring it over the chocolate.
- Add the rainbow chips while the ganache is still wet: The ganache sets faster than you think, especially if your kitchen is cool. Have your sprinkles and candy pieces ready to go the moment the ganache is spread. If the ganache firms up before you add the toppings, they won't stick.
- Chill the dough if it's too sticky to handle: On warm days, the dough can get soft enough that it's hard to roll into balls without it sticking to your hands. A 15-minute rest in the fridge fixes that. I don't do this step in winter, but in summer it's almost always necessary in my kitchen.
Variations
- Peanut butter ganache swirl: After spreading the ganache, drop small spoonfuls of warm peanut butter on top and drag a toothpick through to swirl them together. The peanut butter and chocolate combination is one of Saad's favorites — he always asks if there's "the peanut butter one" version whenever I make these.
- Mint chocolate version: Add ¼ teaspoon of peppermint extract to the ganache when you stir it. Swap the rainbow chips for crushed candy canes. This is a good variation for the holidays — it has that cool mint-chocolate combination that works really well with the fudgy base.
- Espresso chocolate: Add 1 teaspoon of instant espresso powder to the dry ingredients. You won't taste coffee — it just makes the chocolate flavor deeper and more intense. This is my personal favorite version. I make it for myself when I'm not baking for the kids.
- Gluten-free version: I've tried this with a 1:1 gluten-free flour blend (the kind at Walmart or Costco) and the texture holds up well. The cookies spread slightly less, so flatten them a bit more before baking. The ganache and toppings are naturally gluten-free so no adjustments needed there.
- Holiday edition: Swap the rainbow chips for red and green sprinkles and red and green M&Ms. I made these for a cookie box last December alongside my Soft Gingerbread Cookies with Maple Glaze and the colors looked great together in the tin. Simple swap, totally different feel.
Serving and Storage
Serving
Serve these at room temperature — that's when the ganache has the best texture, slightly firm on top but not hard. A glass of cold milk is the obvious pairing, and I'm not going to pretend that's a cliché, because it genuinely works. If you want to make them feel a bit more dessert-y, warm them for 10 seconds in the microwave and the ganache softens back up nicely. I serve them at room temperature on a plate for parties and nobody ever complains.
Storage
Store in an airtight container at room temperature for up to 4–5 days. If you're stacking them, put a sheet of wax paper between each layer — the ganache can stick to the bottom of the cookie above it and pull off in chunks. I learned this the messy way. For longer storage, freeze them in a single layer first until the ganache is solid, then transfer to a freezer bag. They keep well for up to 2 months and thaw at room temperature in about 30 minutes.

Frequently Asked Questions
Can I use milk chocolate instead of semisweet for the ganache?
Yes, you can. Milk chocolate makes the ganache sweeter and a bit milder, which my kids actually prefer. The trade-off is that milk chocolate ganache takes slightly longer to set because of the higher sugar content. Semisweet gives you a richer, slightly bitter contrast to the sweet cookie base, which I personally like better — but either works.
Do I have to chill the dough before baking?
Not always, but sometimes yes. If your kitchen is warm or the dough feels sticky and soft when you try to roll it, 15 minutes in the fridge makes a real difference. In cooler weather I skip this step entirely. If you're not sure, just try rolling one ball — if it sticks to your hands and won't hold its shape, pop the dough in the fridge for a bit.
Where do I find rainbow chips or confetti chips?
Look in the baking aisle at Walmart, Target, or Kroger — they're sometimes labeled "confetti chips," "rainbow sprinkles," or "nonpareils." The flat disc-shaped ones look most like the original cosmic brownie topping. If you can't find them locally, regular M&Ms broken in half or any colorful candy-coated chocolate pieces work fine. The look is slightly different but the effect is the same.
Can I skip the ganache and just do sprinkles on top?
You can, but the ganache is what makes these feel like cosmic brownies rather than just chocolate cookies. Without it, the sprinkles won't stick either — they'll just fall off. If you want a simpler version, try pressing the rainbow chips directly into the dough before baking instead. They'll melt in slightly but hold their position. Still good, just a different end result.
Can I make these ahead of time?
Yes — I actually think these are better on day two once the ganache has fully set and the flavors have had time to settle. Bake the cookies, let them cool, add the ganache and toppings, and store them in an airtight container. They're ready to serve the next day with no last-minute work needed. If you're building a cookie box or baking for a party, making them the day before is the move.

COSMIC BROWNIE COOKIES
Ingredients
For the Cookies:
- 1 cup unsalted butter softened
- 1 cup granulated sugar
- ½ cup brown sugar
- 2 large eggs
- 1 teaspoon vanilla extract
- 1 ½ cups all-purpose flour
- ½ cup unsweetened cocoa powder
- 1 teaspoon baking soda
- ½ teaspoon salt
- 1 ½ cups semisweet chocolate chips
- ½ cup colorful candy-coated chocolate pieces like M&Ms
For the Topping:
- ½ cup mini rainbow sprinkles
- ¼ cup candy-coated chocolate pieces
Instructions
Preheat Oven:
- Preheat the oven to 350°F (175°C). Line two baking sheets with parchment paper.
Prepare Cookie Dough:
- In a large bowl, beat the butter, granulated sugar, and brown sugar together until creamy. Add eggs one at a time, then mix in vanilla. In a separate bowl, whisk together flour, cocoa powder, baking soda, and salt. Gradually add the dry ingredients to the butter mixture and mix until just combined. Stir in chocolate chips and candy-coated chocolate pieces.
Shape the Cookies:
- Scoop tablespoon-sized portions of dough and roll them into balls. Place them on the prepared baking sheets, spacing them about 2 inches apart. Flatten each dough ball slightly with the back of a spoon.
Add Toppings:
- Sprinkle mini rainbow sprinkles and additional candy-coated chocolate pieces on top of each cookie.
Bake:
- Bake for 10–12 minutes, or until the edges are set but the centers are still slightly soft. Allow the cookies to cool on the baking sheet for 5 minutes before transferring them to a wire rack to cool completely.
Notes
Store cookies in an airtight container at room temperature for up to 4 days. For longer storage, freeze the cookies for up to 2 months. Customization:
Feel free to add your favorite mix-ins, such as chopped nuts or caramel bits, to the cookie dough for extra flavor and texture.
These cookies have become a regular in my kitchen — not just because Zainab asks for them, but because they're genuinely one of the easiest ways to make something that looks impressive without a lot of effort. The ganache step sounds fancy, but it takes less than five minutes and it's really hard to mess up if you keep the cream below boiling.
I make them most often when I need something for a school event or a gathering and I want to bring something that doesn't look like it came out of a box. The rainbow chips do most of the visual work — people see the colors and get excited before they've even tasted one. If you want something equally crowd-friendly on the chocolate front, my Chocolate Covered Strawberry Layer Cake is another one that gets that same reaction at a table.
Make a double batch if you're baking for more than four people. I'm not joking — a single batch is twelve to fourteen cookies and they go fast. The good news is the dough comes together quickly enough that doubling it isn't a big deal, especially if you have two baking sheets going at once.
Whether you're making these for a birthday, a cookie tin, or just a random Tuesday when someone needs chocolate, this is a recipe that delivers every time. 🍪🌈✨
If you liked these, you'll probably enjoy these too:





Comments
No Comments