With the increase of shale gas resource exploitation in our country during recent decades, the situations of low gas production, fast production decline rate, and low flowback rate have been appearing in field production. It is an urgent problem to be solved in shale gas production and it is therefore necessary to study the interaction of the shale gas reservoir and the detained fracturing fluid. In this paper, the Longmaxi Formation shale samples of Sichuan Basin were selected for a water invasion experiment. The fracture propagation law, the water invasion front location, and the water invasion thickness of deep and shallow shale reservoirs after water invasion were compared and analyzed by CT scanning technology. Based on the analysis of the experimental mechanism, a numerical simulation model was established. The dimensionless permeability and thickness of the fracturing fluid invasion layer were introduced to analyze the positive and negative effects of fracturing fluid retention on the reservoir. The results show that during the hydraulic fracturing of shale gas wells, fracturing fluid can quickly enter the complex fracture network, and then slowly enter the shale matrix under various mechanisms to form the fracturing fluid invasion layer. Compared with shallow shale reservoirs, deep shale reservoirs have lower porosity and permeability, which propagates microfractures in the matrix induced by fracturing fluid retention, and results in a smaller fracturing fluid invasion layer thickness. Both the negative effect of fracturing fluid retention on shale damage and the positive effect of microfracture formation and propagation exist simultaneously. The higher the dimensionless fracturing fluid invasion layer permeability, the more complex the fracture network formed in the fractured reservoir will be, resulting in a longer stable production period and a better development effect. When the dimensionless fracturing fluid invasion layer permeability is greater than 1, that is, when the positive effect of fracturing fluid retention is greater, and the thicker the dimensionless fracturing fluid invasion layer is, the better the development effect will be. Combining reservoir characteristics and fracture development, the key to obtaining high productivity of a shale gas well is to optimize the soaking time and the speed of flowback in order to extend the stable production period. In this paper, the characteristics of the fracturing fluid invasion layer and the influence of fracturing fluid retention on gas well productivity are deeply studied, which provides a certain theoretical basis for the optimization of shale gas extraction technology and the improvement of the gas–water two-phase productivity prediction method for fractured horizontal wells.