Preheat the oven to 350°F (175°C) and grease a 9-inch square baking pan.
Whisk together flour, baking powder, baking soda, salt, cinnamon, nutmeg, and ginger.
Beat the softened butter, granulated sugar, and brown sugar until light and fluffy.
Add the eggs one at a time, mixing well after each addition.
Stir in the vanilla extract and sour cream.
Add the dry ingredients alternately with the apple cider, mixing just until combined.
Gently fold the diced apple into the batter.
Spread the batter evenly into the prepared baking pan.
For the crumb topping, combine flour, brown sugar, cinnamon, melted butter, and chopped pecans until coarse crumbs form.
Sprinkle the crumb mixture evenly over the cake batter.
Bake for 38–42 minutes, or until a toothpick inserted into the center comes out clean.
Let the coffee cake cool in the pan for 15 minutes.
For the optional glaze, whisk powdered sugar, apple cider, and vanilla until smooth.
Drizzle the glaze over the cooled cake before slicing and serving.