Preheat the oven to 350 degrees F. Place 12 glass half-pint jars on a rimmed baking sheet. Mix the flour, baking powder, salt, cocoa and brown sugar together in a large bowl. Whisk in all the liquid ingredients until smooth.
Use a scoop to evenly distribute the batter into the 12 jars. Pour in the center, so the batter doesn't run down the sides. Carefully place the baking sheet in the oven and bake the cakes for 20-25 minutes, until a toothpick inserted into the center of a cake comes out clean. Remove from the oven and cool to room temperature. Once cool, screw the lids on the jars to store.
To serve, place one heaping scoop of vanilla ice cream on the top of each cake. Pour a scant amount of root beer over the ice cream so it fizzes up. Serve with a spoon!