Preheat oven to 350°F. Line bottom and sides of an 8x8" baking dish with parchment paper.
Peel and grate the apples on the large holes of a box grater, set aside.
Whisk flour, baking powder, baking soda, kosher salt, and ground cinnamon together in a bowl.
Add melted butter, white and brown sugars, vanilla and eggs to bowl and mix to combine. Add apples and dry ingredients to wet and mix until combined.
Scrape batter into prepared baking dish and smooth top. Bake until a tester inserted into the center comes out clean, 35–40 minutes. Transfer to a wire rack and let cake cool in pan.
Using the end of a wooden spoon or chopstick, poke holes all over top of cake. Make the caramel topping.
Caramel Topping
Brown butter in skillet over medium heat, stirring until milk solids are deep brown, about 2-3 minutes. Add the brown sugar, corn syrup, heavy cream, vanilla.
Stirring constantly, bring mixture to a boil and cook until sugar is melted, 1–2 minutes (an instant-read thermometer should register 225°F). Pour caramel over cake holes and spread to edges if needed. Sprinkle flaky sea salt on top (optional).
Let cake cool 15 minutes before cutting cake into squares.