Chocolate chip cookie bars deliver the flavor of a drop cookie with less shaping and more control over the center texture. Melted butter and an extra egg yolk make these bars chewy; the key is measuring flour carefully and removing the pan while the center is set but still soft.
Use the Right Pan and Parchment
An 8-inch square metal pan gives the intended thickness and bake time. A 9-inch pan makes thinner bars that finish sooner, while glass heats differently and can overcook the edges before the center is ready. Leave parchment overhang on two sides so the cooled slab can be lifted out cleanly.

Mix for a Chewy, Even Crumb
Cool the melted butter for about five minutes so it does not scramble the egg. Whisk the sugars into the butter until glossy, then add the egg, yolk, and vanilla. Once flour enters the bowl, switch to a spatula and fold only until the last dry streak disappears. Overmixing at this stage makes the bars firmer and more cake-like.
For consistent flour measurement, weigh 180 grams or use the spoon-and-level method. Scooping directly with the measuring cup compresses flour and is a common reason cookie bars turn out dry.

How to Tell When the Bars Are Done
Look for golden edges and a center that no longer appears wet. A toothpick inserted near the middle should pick up moist crumbs, not raw batter. The residual heat of the pan continues cooking the center, so waiting for a completely clean toothpick produces drier bars.
Cooling, Cutting, and Storage
- Cool in the pan for 15 minutes before lifting by the parchment.
- For very neat squares, let the slab cool completely and wipe the knife between cuts.
- Store cooled bars in a sealed container at room temperature for up to three days.
- Freeze individual bars with parchment between layers, then thaw at room temperature.
- Warm a bar briefly before serving if you want the chocolate soft again.
If you enjoy bar desserts, try our coffee cake muffins or fresh peach cobbler, and browse more Dessert Recipes.
Raw flour and raw egg can contain harmful bacteria, so do not taste unbaked dough. The FDA explains this in its guidance on flour and raw dough safety.
Soft Chocolate Chip Cookie Bars
Buttery, chewy cookie bars with warm vanilla flavor, crisp golden edges, and plenty of melted chocolate.
Prep Time: 10 minutes
Cook Time: 22 minutes
Total Time: 47 minutes
Servings: 16 bars
Ingredients
- 1/2 cup unsalted butter, melted and cooled for 5 minutes
- 3/4 cup packed light brown sugar
- 1/4 cup granulated sugar
- 1 large egg, at room temperature
- 1 large egg yolk, at room temperature
- 2 teaspoons pure vanilla extract
- 1 1/2 cups all-purpose flour, spooned and leveled
- 1/2 teaspoon baking soda
- 1/2 teaspoon fine salt
- 1 cup semisweet chocolate chips, divided
- 1/2 cup chopped walnuts or pecans, optional
- 1/4 teaspoon flaky sea salt for topping, optional
Instructions
- Prepare the pan: Preheat the oven to 350°F (175°C). Line an 8-inch square baking pan with parchment paper, leaving enough overhang on two sides to lift the bars out later.
- Mix the butter and sugars: In a large bowl, whisk the melted butter, brown sugar, and granulated sugar until the mixture looks smooth and glossy.
- Add the eggs and vanilla: Whisk in the egg, egg yolk, and vanilla until fully combined. The mixture should become slightly thicker.
- Add the dry ingredients: Add the flour, baking soda, and salt. Fold gently with a spatula just until no dry streaks remain.
- Fold in the chocolate: Fold in 3/4 cup of the chocolate chips and the chopped nuts, if using. Avoid overmixing.
- Fill the pan: Spread the dough evenly in the prepared pan. Press the remaining chocolate chips over the top and sprinkle with flaky sea salt if desired.
- Bake the bars: Bake for 20 to 24 minutes, until the edges are golden and the center looks set but still slightly soft. A toothpick inserted near the center should come out with moist crumbs rather than wet batter.
- Cool and slice: Let the bars cool in the pan for 15 minutes. Lift them out using the parchment paper and transfer to a wire rack. Slice into 16 squares once they are warm but firm enough to cut cleanly.
Notes
For the softest bars, remove them from the oven when the center is set but still looks slightly underbaked. They continue to firm as they cool.
