Skip to content
Afoodrink logo

Magic Bars

These classic layered cookie bars are chewy, crunchy, and simple to make with pantry-friendly ingredients. A buttery graham cracker crust holds chocolate chips, coconut, nuts, and sweetened condensed milk in every square

Total

45 min

Servings

24 bars

Level

Easy

Magic bars, also called seven-layer bars or hello dolly bars, are the kind of dessert that looks more complicated than it is. You build them right in the pan, layer by layer, then let the oven do the work.

The base is a simple graham cracker crust. Sweetened condensed milk binds the toppings together as it bakes, turning the chocolate, coconut, and nuts into a chewy, sliceable topping.

These bars are great for bake sales, holidays, lunchbox treats, or any time you need a dessert that travels well. Let them cool fully before cutting for the cleanest squares.

01What you'll need

Ingredients

8 items · 24 bars

  • 1/2 cup unsalted butter, melted, plus more for the pan
  • 1 1/2 cups graham cracker crumbs, from about 10 to 11 full sheets
  • 1/4 teaspoon fine salt
  • 1 cup semi-sweet chocolate chips
  • 1 cup butterscotch chips or white chocolate chips
  • 1 1/3 cups sweetened shredded coconut
  • 1 cup chopped pecans or walnuts
  • 1 can (14 ounces) sweetened condensed milk

02How to make it

Step-by-step

  1. 1. Heat the oven

    Heat the oven to 350°F. Lightly butter a 9-by-13-inch baking pan, then line it with parchment paper, leaving a little overhang on two sides. The overhang helps you lift the bars out later.

  2. 2. Make the crust

    Stir the melted butter, graham cracker crumbs, and salt in a medium bowl until the crumbs look evenly moistened, like damp sand.

  3. 3. Press the crust

    Tip the crumb mixture into the prepared pan. Press it firmly and evenly across the bottom with the bottom of a measuring cup or clean hands. A firmly packed crust helps the bars hold together.

  4. 4. Add the chips

    Sprinkle the chocolate chips and butterscotch chips evenly over the crust. Try to spread them all the way to the corners so every bar gets a good mix of toppings.

  5. 5. Add coconut and nuts

    Scatter the shredded coconut over the chips, then sprinkle the chopped pecans or walnuts on top. Keep the layers even, but do not press them down yet.

  6. 6. Pour on the condensed milk

    Slowly drizzle the sweetened condensed milk over the whole pan. Cover as much of the surface as you can. Use a spatula to gently nudge it into bare spots, but do not fully mix the layers.

  7. 7. Bake until golden

    Bake for 25 to 30 minutes, until the edges are bubbling and the coconut and nuts are lightly golden. The center may still look a little soft, but it will set as it cools.

  8. 8. Cool and cut

    Let the pan cool on a wire rack for at least 2 hours. For neater slices, chill the bars for 30 minutes after they cool. Lift them out with the parchment and cut into 24 squares or rectangles.

03From our kitchen

Cook's tips

  • Make-ahead: Magic bars are a good make-ahead dessert. Bake them up to 2 days before serving and keep them covered at room temperature or in the fridge.
  • Storage: Store the cut bars in an airtight container at room temperature for up to 4 days, or in the refrigerator for up to 1 week. Put parchment between layers so they do not stick together.
  • Freezing: Freeze the bars in a sealed container for up to 2 months. Thaw at room temperature for about 30 minutes before serving.
  • Clean slicing: Cool the bars completely before cutting. A warm knife will drag the toppings and make messy edges. For very tidy bars, chill first and wipe the knife between cuts.
  • Nut swaps: Pecans and walnuts are classic, but almonds, hazelnuts, or peanuts also work. For a nut-free version, replace the nuts with more coconut, crushed pretzels, or extra chips.
  • Chip swaps: Use milk chocolate chips, dark chocolate chips, peanut butter chips, or white chocolate chips. Keep the total amount of chips about the same so the bars set well and do not become too sweet or loose.

Cook's note

Sweetened condensed milk is not the same as evaporated milk. Condensed milk is thick and sweet, and it is what holds these bars together. Evaporated milk is thinner and unsweetened, so it will not work in this recipe.

04Frequently asked

Questions & answers

Why are my magic bars falling apart?

They may need more cooling time, or the crust may not have been pressed firmly enough. Let the bars cool completely before cutting. If they still seem soft, chill them for 30 to 60 minutes.

Can I make magic bars without coconut?

Yes. Replace the coconut with extra chopped nuts, crushed pretzels, rolled oats, or more chocolate chips. The texture will be different, but the bars will still bake well.

Do I need to bake the graham cracker crust first?

No. The crust bakes along with the toppings. Just press it firmly into the pan before adding the layers.

Can I use a smaller pan?

A smaller pan will make thicker bars, and they may need more time to bake. An 8-by-8-inch pan is too small for the full recipe. If using that size, halve the ingredients and start checking around 25 minutes.

How do I know when magic bars are done?

Look for bubbling around the edges and light golden color on the coconut and nuts. The center should not be liquid, but it can look slightly soft. It will firm up as it cools.

05Keep cooking