## 2 Materials and Methods  
_Device fabrication: fluorine tin oxide (FTO)-coated glasses were cleaned with HellmanexTM_ soap solution in water using a toothbrush, then, they were ultrasonicated in distilled water, acetone and isopropanol. Finally, they were dried with an air flow and treated with UV/O\({}_{3}\) for 30 min. Compact and mesoporous TiO\({}_{2}\) layers were deposited onto the clean FTO substrates by spin-coating 0.3 M Ti(iPrO)\({}_{2}\)(acac)\({}_{2}\) solution in 2-propanol using 4000 rpm, 1000 rpm/s for 25 s. The substrates were dried at 120 \({}^{\circ}\)C for 5 min, followed by thermal annealing at 450 \({}^{\circ}\)C for 30 min. Once the substrates were cold, they were plunged into a solution of 40 mM TiCl\({}_{4}\) at 70 \({}^{\circ}\)C for 30 min. Then, they were rinsed with distilled water and ethanol and dried with a strong air flow. The mesoporous TiO\({}_{2}\) layer was deposited by using a a commercial paste (30 NR-D, Greatcell) with a 30 nm particle size diluted in ethanol (1:7 weight ratio) and spin-coated at 6000 rpm, 1000 rpm/s for 30 s. Then, they were heated by using the same conditions as compact TiO\({}_{2}\) layer. A compact SnO\({}_{2}\) layer was grown by chemical bath deposition (CBD) technique on top of the FTO substrates. The solution was prepared dissolving first 0.75 g of urea in 60 mL of deionised H\({}_{2}\)O. Then, 15 \(\upmu\)L of mercaptopropionic acid and 750 \(\upmu\)L of HCl (37 wt%) were added. Finally, SnCl\({}_{2}\cdot 2\)H\({}_{2}\)O was added to the solution to a final concentration of 0.012 M (162 mg). The solution was stirred for 2 min and transferred to a glass container were the substrates are immersed vertically. The deposition was made by putting them in a lab oven at 70 \({}^{\circ}\)C for 3 h. Then, the substrates were transferred to another glass container with H\({}_{2}\)O, and they were ultrasonicated for 2 min in order to remove any loosely bound material. Then, the substrates were dried and annealed at 180 \({}^{\circ}\)C for 1 h. Prior to perovskite deposition, SnO\({}_{2}\) films must be treated with UV/O\({}_{3}\) for 30 min. Methylammonium lead iodide (MAPbI\({}_{3}\)) was deposited by performing two steps: 80 \(\upmu\)L of a 1 M PbI\({}_{2}\) solution in DMF:DMSO (9:1, vol%) was spin-coated at 2000 rpm, with 2000 rpm/s for 90 s, and after 60 s, 100 \(\upmu\)L of a 50 mg/mL MAI solution in IPA was spin-coated on top of the PbI\({}_{2}\) while spinning. The samples were treated by thermal annealing for 45 min at 100 \({}^{\circ}\)C.  
Triple cation perovskite, CsFAMAPbIBr, was prepared by dissolving 1.2 M PbI\({}_{2}\), 1.04 M formamidinium iodide (FAI), 0.16 M PbBr\({}_{2}\), 0.16 M methylammonium bromide (MABr), and 0.1 M of CsI into DMF:DMSO (4:1, volume ratio). To help the dissolution, it was stirred at 60 \({}^{\circ}\)C for 30 min. Then, the solution was filtered and 40 \(\upmu\)L were spin-coated with a two-step program, first 2000 rpm, 500 rpm/s and 12 s, and then 5000 rpm 500 rpm/s 25 s. Ten seconds before the end of the spinning process, 100 \(\upmu\)L of chlorobenzene were droppedin the centre of the substrate while spinning. Then, the films were annealed at 100 \({}^{\circ}\)C/1 h. We prepared the devices with a continuous N\({}_{2}\) flow to remove the solvent atmosphere that can affect the perovskite morphology. After that, a 60 mM spiro-OMeTAD solution in chlorobenzene with 4-tert-butylpiridine (TBP), LiTFSI (1.8 M solution in acetonitrile) and Co(III)TFSI (0.25 M solution in acetonitrile) as dopants was prepared as hole selective contact. The molar ratio employed was 1 spiro-OMeTAD:3.3 TBP:0.5 LiTFSI:0.05 Co (III) TFSI. Then, 35 \(\mu\)L of this solution were spin-coated at 4000 rpm, 2000 rpm/s for 30 s on top of the perovskite layer. The devices were completed by evaporating 80 nm of Au under high-vacuum conditions. _Aging process_: Devices were stored in the dark under dry conditions (<10% H\({}_{2}\)O, obtained via a synthetic airflow) for up to 6 weeks.