Preheat your oven to 350°F (175°C). Grease a 9x13-inch baking pan or line it with parchment paper for easy removal.
In a large mixing bowl, cream together the softened butter, granulated sugar, and brown sugar until light and fluffy.
Add the eggs one at a time, mixing well after each addition. Stir in the vanilla extract.
In a separate bowl, whisk together the flour, baking soda, and salt. Gradually add the dry ingredients to the wet ingredients, mixing until just combined.
Fold in the chocolate chips and nuts, if using.
Spread the batter evenly in the prepared baking pan.
Sprinkle the coarse sea salt over the top of the batter.
Bake in the preheated oven for 25-30 minutes, or until the edges are golden brown and a toothpick inserted in the center comes out with a few moist crumbs.
Allow the bars to cool in the pan for about 10 minutes before transferring them to a wire rack to cool completely. Cut into squares and serve.