Preheat oven to 350°F (175°C) and line a standard 12-cup muffin tin with paper liners.
In a medium bowl, whisk together the flour, baking powder, baking soda, salt, cinnamon, and ginger.
In a large bowl, whisk together the granulated sugar, vegetable oil, and eggs until smooth.
Fold the grated carrots into the wet mixture until evenly distributed.
Gradually stir the dry ingredients into the wet ingredients until just combined; do not overmix.
Divide the batter evenly among the muffin cups, filling each approximately three-quarters full.
Bake for 20 to 22 minutes, or until a toothpick inserted into the center of a cupcake comes out clean.
Allow cupcakes to cool in the tin for 5 minutes before transferring to a wire rack to cool completely.
Prepare the frosting by beating the cream cheese and butter together until smooth and creamy.
Add the powdered sugar and vanilla extract to the cream cheese mixture and beat until light and fluffy.
Pipe or spread the frosting onto the completely cooled cupcakes.