Roof failure significantly threatens the safety and stability of grottoes. For the layered roof of sandstone grottoes, the failure process is closely related to bedding effects of crack propagation. Taking the Yuanjue Cave as an example, the progressive failure process of the layered roof was summarized. The mechanisms of crack propagation in the roof were analyzed theoretically, and bedding effects together with influencing factors of crack propagation were explored. Results showed that the instability process of the layered roof in sandstone grottoes can be summarized into four stages: tensile fracture of the roof, vertical expansion of cracks, horizontal deflection of cracks, and instability collapse of blocks. The development and propagation of cracks constituted the intrinsic cause of the instability of layered roofs. A fracture mechanics model for crack propagation in layered roofs was established considering the bedding effect, and the criteria for vertical expansion of cracks in grotto roofs was derived. Moreover, the fracture criterion of crack competition was modified in combination with the bedding effect, revealing that an increase in interlaminar cohesion inhibited the crack deflection mode. The crack deflection mode in grotto roofs was jointly determined by the stress at the crack-tip (σfxx and σfyy), the strength of the rock layers and bedding plane (σ't, μ and c). To control the crack propagation in roofs, the engineering reinforcement of grotto roofs can be achieved by weakening bedding effects and indirectly reducing the roof span. This study is of great significance for revealing the progressive failure process and optimizing the reinforcement scheme of layered roofs in grottoes.