This article investigates the impact of metal-organic frameworks (MOFs) on the performance and stability of perovskite solar cells (PSCs), specifically focusing on the type of metal and the morphology of the MOF. Two types of MOFs, copper-benzene-1,3,5-tricarboxylate (Cu-BTC MOF) with spherical morphology and cobalt-benzene-1,3,5-tricarboxylate (Co-BTC MOF) with rod morphology, are synthesized and spin-coated on TiO2 substrates to form FTO/TiO2/MOF/CH3NH3PbI3/C-paste PSCs. The morphology and size of the MOFs are characterized by scanning electron microscopy (SEM), and the crystallinity and residual PbI2 of the perovskite films are analyzed by X-ray diffraction (XRD). The results show that the Co-BTC MOF PSC exhibits the highest power conversion efficiency (PCE) of 10.4% and the best stability, retaining 82% of its initial PCE after 264 h of storage in ambient air. The improved performance and stability are attributed to the enhanced crystallinity and reduced residual PbI2 of the perovskite film after Co-BTC MOF modification. The paper showcases the immense potential of MOF-based interlayers to revolutionize PSC technology, offering a path toward next-generation solar cells with enhanced performance and longevity.