Preheat your oven to 350°F (175°C). Line a baking sheet with parchment paper if desired.
In a mixing bowl, whisk together the flour, cocoa powder, baking soda, and salt. Set aside.
In another bowl, use an electric mixer to cream the softened butter and granulated sugar together until light and fluffy.
Add the egg and vanilla extract to the butter-sugar mixture and mix until well combined.
Gradually add the dry ingredients to the wet ingredients, mixing until a dough forms. Be careful not to overmix.
Use a rubber spatula to scrape down the sides of the bowl and ensure everything is combined.
Take small portions of the dough and roll them into balls (about 1 tablespoon each), then place them on the prepared baking sheet, spaced a couple of inches apart.
Bake in the preheated oven for 10-12 minutes, or until the edges are set. The centers might look slightly underbaked; they will firm up as they cool.
Allow the cookies to cool on the baking sheet for 5 minutes before transferring them to a wire rack to cool completely.
For added flavor, consider mixing in chocolate chips or nuts before rolling the dough into balls.
If you want to decorate them, you can drizzle melted chocolate or icing on top once they have cooled completely.