The deformation and failure of coal walls in front of a working face cause significant difficulties during mining operations. This study reveals the nonuniform distribution of bearing pressure in front of coal walls based on in situ monitoring data and numerical simulation. Therefore, an eccentric compression mechanical model was established to study the deformation and failure characteristics of a coal wall. The slenderness ratio of the compression bar is introduced to define coal walls. The results showed that instability failure occurs when λ > λc and material failure occurs when λ ≤ λc. The instability failure‐type coal wall spalling was related to the mining height, eccentricity of roof pressure, the horizontal force, and the reaction moment of the floor. The material failure‐type coal wall spalling was related to the cohesion, the internal friction angle of the coal, the upper pressure, and the horizontal force of coal walls. Unstable and destructive coal wall peeling usually occurs at a height of 0.5–0.6 times the mining height, while material damage to coal wall peeling is determined to occur within the range of 0.4–0.6 times the mining depth. The findings contribute to the understanding of the deformation and failure of coal walls.