In a saucepan over medium heat, whisk together cocoa powder, granulated sugar, and salt. Gradually whisk in the whole milk until smooth and combined. Cook the mixture, stirring constantly, until it thickens slightly, about 5 minutes. Remove from heat and stir in the vanilla extract. Let the mixture cool to room temperature.