Mesoporous structured electron transport layers (ETLs) in perovskite solar cells (PSCs) have an increased surface contact with the perovskite layer, enabling effective charge separation and extraction, and high-efficiency devices. However, the most widely used ETL material in PSCs, TiO2, requires a sintering temperature of more than 500 °C and undergoes photocatalytic reaction under incident illumination that limits operational stability. Recent efforts have focused on finding alternative ETL materials, such as SnO2. Here we propose mesoporous MoS2 as an efficient and stable ETL material. The MoS2 interlayer increases the surface contact area with the adjacent perovskite layer, improving charge transfer dynamics between the two layers. In addition, the matching between the MoS2 and the perovskite lattices facilitates preferential growth of perovskite crystals with low residual strain, compared with TiO2. Using mesoporous structured MoS2 as ETL, we obtain PSCs with 25.7% (0.08 cm2, certified 25.4%) and 22.4% (1.00 cm2) efficiencies. Under continuous illumination, our cell remains stable for more than 2,000 h, demonstrating improved photostability with respect to TiO2.