Preheat your oven to 350°F.
Grease a 13x18-inch baking sheet with butter or cooking spray, or line it with parchment paper.
In a large mixing bowl, whisk together the dry ingredients: gluten-free flour, granulated sugar, baking soda, and salt.
In a saucepan, melt the butter, water, and cocoa powder over medium heat until smooth. Let it cool slightly.
Pour the chocolate mixture into the dry ingredients, then add eggs, buttermilk, and vanilla extract. Mix until smooth.
Pour the batter into the prepared baking sheet and bake for 20-25 minutes. Check for doneness with a toothpick.
While the cake is baking, prepare the frosting by melting butter, cocoa powder, and milk in a saucepan. Stir until smooth, then whisk in powdered sugar and vanilla extract.
After the cake has baked and cooled for about 10 minutes, pour the warm frosting over the top and spread it evenly.