Prep the beet and oven: Preheat your oven to 350°F (175°C). Toss the whole peeled beet with a little oil, wrap in foil, and roast for about 45 minutes until you can easily pierce it with a fork. Let cool enough to handle, then grate it finely using a box grater or food processor.
Mix dry ingredients: In a medium bowl, whisk together the flour, baking soda, baking powder, salt, cocoa powder, brown sugar, and granulated sugar until there are no large lumps of cocoa left.
Combine wet ingredients: In a separate large bowl, beat the eggs lightly with a fork or whisk. Add the oil, buttermilk, vanilla extract, and grated beet. Whisk until everything is fully incorporated—the mixture will look slightly speckled from the beet.
Bring it together: Pour the dry ingredients into the wet and fold with a spatula just until combined. Don't overmix; you'll still see streaks of flour and cocoa when you stop, which is exactly right. The batter should be thick but pourable.
Bake: Pour the batter into a greased 9-inch round cake pan or an 8×8 square pan. Bake for 30-35 minutes in a round pan, or 25-30 minutes if using an 8×8. The cake is done when a toothpick inserted into the center comes out clean with just a few moist crumbs clinging to it (not wet batter).
Cool and serve: Let the cake cool in the pan for about 10 minutes, then turn it out onto a wire rack to cool completely before slicing. Sprinkle flaky sea salt on top if you're serving it as is—this really elevates the flavor against the sweetness.