M&M Cookie Bars

Jump to Recipe

M&M Cookie Bars!! One of my favorite desserts of all times. And also be warned - one is NOT to be left alone with a pan of these! These cookie bars are on par with my famous cheesecake cookie bars. You may want to check those out as well!

An overhead shot of 16 square Christmas MM Cookie Bars


 
  • 🕒 Total Time: 35 minutes (10 min prep + 25 min bake)
  • 👪 Servings: 24 bars
  • 🍝 Cuisine Type: American / Dessert Bars
  • 🧂 Flavor Profile: Soft, chewy cookie bars loaded with chocolate chips and colorful M&M’s that are buttery, sweet, and festive
  • 📖 Dietary Info: Contains dairy, eggs, and gluten; vegetarian
  • 📦 Storage Notes: Store at room temperature in an airtight container for 3–4 days; can freeze tightly wrapped for up to 2 months
  • Why You’ll Love It: All the flavor of classic cookies with zero scooping. Fast, fun, colorful bars perfect for holidays, parties, or gifting.

Summarize and save this content on...

Why I Love This Recipe

Is there anything better than a soft homemade cookie in bar form? Where the edges are just lightly golden brown and a tad bit crunchy... and the inside is gooey and soft and melts in your mouth? Let me answer that for you.... no.

It doesn't get better than cookie bars when it comes to a quick and easy dessert that literally every single person will love. These cookie bars are my favorite sugar cookie recipe baked up in bar form. You all know how I love the giant M&M cookies and these are just the perfect bar form for that perfect cookie!

Jump to:

Ingredients & Substitutions

Mise-en-place with all the ingredients to make m&m cookie bars

Substitutions

🍫 Candy + Chocolate Swaps

  • M&Ms — the classic, but any color mix works (holiday themes are always fun).
  • Peanut butter M&Ms or Reese’s Pieces — for a nutty twist.
  • Chocolate chips (semi-sweet, dark, or white) — mix them in or sub entirely.
  • Chopped chocolate bars — for gooier pockets of melty chocolate.
  • Mini candies — like chopped Snickers, Twix, or Kit Kats for a fun mashup.

🧈 Fat + Sugar Variations

  • Brown butter — adds a nutty, caramelized depth.
  • Coconut oil — for a dairy-free version with a hint of flavor.
  • Light brown sugar — milder sweetness.
  • Dark brown sugar — deeper molasses flavor and extra chew.

🥚 Flour & Texture Swaps

  • All-purpose flour — classic for soft, chewy bars.
  • Bread flour — for a chewier, slightly denser texture.
  • Whole wheat pastry flour — adds nuttiness and fiber without heaviness.
  • Gluten-free 1:1 flour blend — works great; just chill the dough before baking.

🧂 Flavor Boosters

  • Espresso powder — intensifies the chocolate flavor.
  • Flaky sea salt on top — makes them next-level.
  • Cinnamon or nutmeg — adds warmth and depth.
  • Vanilla bean paste — for a richer, aromatic flavor.

🍪 Fun Add-Ins

  • Chopped nuts — pecans, walnuts, or almonds for crunch.
  • Toffee bits — for caramel flavor and texture.
  • Mini marshmallows — for a gooey s’mores version.
  • Shredded coconut — adds chew and a hint of sweetness.

*For a full list of ingredients and instructions please see recipe card below.

A glass mixing bowl with melted butter and brown sugar.

Step 1: Preheat the oven to 350 degrees. In a large bowl, combine the melted butter and brown sugar and mix with a wooden spoon for 1 minute until combined.

A glass mixing bowl with a mix of melted butter and sugar, with two eggs added but not mixed in yet.

Step 2: Add the vanilla and eggs, making sure to scrape down the sides of the bowl, and mix until fully incorporated.

A glass mixing bowl with wet ingredients and dry ingredients just added.

Step 3: Add the dry ingredients into the bowl and slowly mix until just combined. The batter will be a bit stiff, but that's normal.

A glass mixing bowl with M&M cookie batter with red and green M&Ms just added.

Step 4: Fold in 1 cup of the Milk Chocolate M&M’s.

A square baking pan with M&M cookie batter and topped with red and green M&Ms.

Step 5: Spray a 9x9 metal baking pan (see note above) with baking spray and line it with parchment paper. Spoon the batter into the prepared baking sheet and sprinkle with the remaining Milk Chocolate M&M’s and Maldon sea salt if desired.

A square baking pan with M&M cookie square baked in it.

Step 6: Transfer it into the oven. Bake for 35-40 minutes. Once the bars have baked, remove them from the oven and let cool for at least 2 hours before cutting and serving.

Cut these into squares once cooled, and store in an airtight container for a few days. You can also store in the fridge to keep them longer, about two weeks.

We have not had leftovers for these in our household! However, if you want to freeze them, store these bars in a freezer bag or airtight container for about 3 months. Defrost in the fridge or outside to serve.

  • Don’t skimp on the brown sugar. Brown sugar adds moisture and chew. It’s what makes these bars taste rich and caramel-y. The combo of white + brown is key.
  • Mix just until combined. Overmixing = tough bars. Once the flour disappears, you’re done. Fold in the M&Ms gently so they don’t crack apart.
  • Line your baking dish. Parchment paper with a little overhang makes it so easy to lift out the entire slab and cut perfect squares. No sticking, no crumbling.
  • Press the dough evenly. Use your hands or an offset spatula to spread the dough to the edges. Even thickness = even baking.
  • Add extra M&Ms on top. Press a handful into the surface before baking so the colors stay bright and pretty, it’s the bakery-style finishing touch.
  • Don’t overbake! Pull them when the center still looks slightly underdone. They’ll set as they cool and stay soft and chewy instead of dry.
  • Cool completely before slicing. This is the hardest part, but it’s what gives you clean edges and bars that hold together instead of crumbling into a cookie avalanche.
  • Switch up the mix-ins. Mini chocolate chips, pretzels, peanut butter chips, chopped nuts, whatever you love. M&Ms play well with others.
  • Store them properly (if they last). Keep in an airtight container to maintain that soft chew. Warm them for 10 seconds if you want a gooey, fresh-from-the-oven moment.
  • Use a 9x9 pan. Don't try and do it in a 9x13 or an 8x8... it won't be the same. Trust me - there's a reason I developed it this way! And a glass or ceramic baking dish doesn't retain heat the same way a metal baking dish does... so use a metal baking dish! And 8x8 (while it's the same shape is only 64 square inches and a 9x9 is 81 inches. So that will WILDLY affect baking time.
  • After the baking time - LET THESE SET FOR 2 HOURS. These cookie bars might look a little under-baked but they need time to finish residual baking once they come out of the oven.
A glass bowl with red and green M&Ms with some M&Ms outside the bowl on the counter.

FAQs

What is the difference between cookies and cookie bars?

Cookie bars are somewhere cakes and cookies. A great and easy way to make a big batch, and the thickness gives them a nice gooeyness. While not all cookie recipes may be suitable for cookie bars, this is a great one! Thickness is also important when baking bars, too thin and it will be too crisp, too thick and the edges will be brittle by the time the center bakes.

Can I add other things to these cookie bars?

Yes! Add nuts, pretzel, chocolate chips- all perfect additions to these bars.

Similar Recipes

If you tried this recipe, please leave a 🌟 star rating and let me know how it goes in the 📝 comments below. Thanks for visiting today

Author: Gaby Dalkin
4.9 from 44 votes
M&M Cookie Bars!! One of my favorite desserts of all times. And also be warned – one is NOT to be left alone with a pan of these!
Prep Time 5 minutes
Cook Time 40 minutes
Total Time 45 minutes
Course Dessert
Cuisine American
Servings 16 bars

Ingredients
  

  • 1 cup butter melted
  • 2 cup light brown sugar
  • 4 teaspoons vanilla extract
  • 2 large eggs
  • 2 cups all purpose flour
  • 1 teaspoon baking powder
  • ¼ teaspoon of baking soda
  • 1 cup Milk Chocolate M&M’s plus extra for garnish
  • Maldon sea salt optional

Instructions
 

  • Preheat oven to 350 degrees.
  • In a large bowl, combine the melted butter and brown sugar and mix with a wooden spoon for 1 minute until combined. Add the vanilla and eggs, making sure to scrape down the sides of the bowl, and mix until fully incorporated.
  • Add the dry ingredients into the bowl and slowly mix until just combined. The batter will be a bit stiff, but that's normal. Fold in 1 cup of the Milk Chocolate M&M’s.
  • Spray a 9x9 metal baking pan (see note above) with baking spray and line it with parchment paper. Spoon the batter into the prepared baking sheet and sprinkle with the remaining Milk Chocolate M&M’s and Maldon sea salt if desired and transfer it into the oven. Bake for 35-40 minutes. Once the bars have baked, remove them from the oven and let cool for at least 2 hours before cutting and serving.

Notes

Don’t skimp on the brown sugar. Brown sugar adds moisture and chew. It’s what makes these bars taste rich and caramel-y. The combo of white + brown is key.
  • Mix just until combined. Overmixing = tough bars. Once the flour disappears, you’re done. Fold in the M&Ms gently so they don’t crack apart.
  • Line your baking dish. Parchment paper with a little overhang makes it so easy to lift out the entire slab and cut perfect squares. No sticking, no crumbling.
  • Press the dough evenly. Use your hands or an offset spatula to spread the dough to the edges. Even thickness = even baking.
  • Add extra M&Ms on top. Press a handful into the surface before baking so the colors stay bright and pretty, it’s the bakery-style finishing touch.
  • Don’t overbake! Pull them when the center still looks slightly underdone. They’ll set as they cool and stay soft and chewy instead of dry.
  • Cool completely before slicing. This is the hardest part, but it’s what gives you clean edges and bars that hold together instead of crumbling into a cookie avalanche.
  • Switch up the mix-ins. Mini chocolate chips, pretzels, peanut butter chips, chopped nuts, whatever you love. M&Ms play well with others.
  • Store them properly (if they last). Keep in an airtight container to maintain that soft chew. Warm them for 10 seconds if you want a gooey, fresh-from-the-oven moment.
  • Use a 9x9 pan. Don't try and do it in a 9x13 or an 8x8... it won't be the same. Trust me - there's a reason I developed it this way! And a glass or ceramic baking dish doesn't retain heat the same way a metal baking dish does... so use a metal baking dish! And 8x8 (while it's the same shape is only 64 square inches and a 9x9 is 81 inches. So that will WILDLY affect baking time.
  • After the baking time - LET THESE SET FOR 2 HOURS. These cookie bars might look a little under-baked but they need time to finish residual baking once they come out of the oven.

Nutrition Information

Calories: 339kcal | Carbohydrates: 48g | Protein: 3g | Fat: 15g | Saturated Fat: 9g | Polyunsaturated Fat: 1g | Monounsaturated Fat: 3g | Trans Fat: 0.5g | Cholesterol: 53mg | Sodium: 160mg | Potassium: 66mg | Fiber: 1g | Sugar: 35g | Vitamin A: 414IU | Vitamin C: 0.1mg | Calcium: 62mg | Iron: 1mg
Tried this Recipe? Tag me Today!Mention @WhatsGabyCookin or tag #whatsgabycooking!

Photography by Matt Armendariz / Food Styling by Adam Pearson

114 Comments

  1. 5 stars
    Making these again today! Using red m&m’s for a belated Galentine’s dinner tonight! These are a tried and true, no fail dessert. So glad I found this recipe at Christmas - it’s my go-to! ❤️

  2. 4 stars
    Hi! I made these. The flavor is so delicious and addictive. Mine are really soft. I baked on a lower rack for 36 minutes. I’m not a great baker. I will move up one rack and bake 2 extra minutes next time. These are so easy and were fun to make with a child helper. Thanks Gaby!

  3. 5 stars
    So delicious and easy. The hardest part was waiting the 2 hours for the bars to cool (as in it was so hard to wait that after an hour I had to try a piece of the edge). The salt sprinkle is key, next time I’ll add more!

  4. Just made these for an Oscar Party I am having tomorrow night and followed the recipe exactly as stated.
    Melted the butter in the microwave and used a wooden spoon to really mix the butter into the brown sugar. Batter was thickened before it went into the pan.
    They came out perfect and just like you said: looked a little underdone when I pulled them out of the oven and then PUT A NOTE ON THEM NOT TO BE TOUCHED for 2 1/2 hours and that was the crucial part!!
    Agree with another review that the maldon salt is SO necessary to give it the perfect balance in the mouth.
    They are pretty to look at and delicious to eat!
    Thanks! Will definitely make again!

  5. Have you tried using chocolate discs instead of m&m’s? Hope it works ‘cause I just popped them in the oven!

  6. 5 stars
    Made these 3x over the holidays... yes THREE. Lol
    Some gifted, some served when hosting, some hoarded for ourselves...

    Recipe was followed to a T....
    Turned out perfectly each time. No issues.
    Melted the butter in the microwave and it pulled everything together perfectly.
    The flakes of salt on the top are 200% mandatory. They really make this treat amazing!
    One more family function this weekend me while I was asked to bring apps, I'm also bringing some of these

    Thanks for the amazing recipe!

  7. 5 stars
    Yum! Followed the recipe to a T and they turned out perfectly. Taking them to work with me tomorrow so I don’t eat the whole pan myself!

    1. Love this recipe! But one question, what if you got brown sugar? Would it not work since you call for light brown sugar?

    1. Made these today and after 45 minutes they are very soupy in the middle. Bought a 9x9 pan and used parchment paper. Batter was thick as recipe stated it would be. Not sure what I’ve done wrong?

  8. I tried these today. They are so tasty but very cakey and not so much cookie like in texture. What could I have possibly done different? Baked for fewer minutes?

  9. I have mini M&M's can i substitute with them ? it calls for 1 cup and then sprinkle the top with them before baking. is that another cup or 1/2 cup ?

  10. I have been cooking the M&M bars for 45 min and they still aren cooked. Very soupy. What did I do wrong? Followed the re I’ve exactly but it wasn’t stiff when I mixed it. It was very liquidy.

    1. hmmmmm it should def be thick when mixed! Are you sure you added the correct amount of flour? That would be why it wouldn't thicken up

    2. Same thing just happened to me. I think there is too much butter. Should probably be one stick of butter instead of one cup. One cup is really a LOT of butter.

    3. I had the same issue! I baked for 55 minutes and they never fully set up. Toothpick came out clean once I removed from the oven but when I cut after cooling for 2 hours, not done.

4.91 from 44 votes (22 ratings without comment)

Leave a Reply

Your email address will not be published. Required fields are marked *

Recipe Rating