The objective of this paper is to identify and explain effects of a government spending shock. After accounting for large military events, I find that in response to a structural unanticipated government spending shock, output, hours, consumption and wages all rise, whereas investment falls on impact. I construct and estimate a dynamic general equilibrium model featuring deep habit formation and show that it successfully explains these effects. In particular, deep habits give rise to countercyclical markups and thus act as transmission mechanism for the effects of government spending shocks on private consumption and wages. In addition, I show that deep habits significantly improve the fit of the model compared to a model with habit formation at the level of aggregate goods.