We performed density functional theory (DFT) calculations to gain additional insight. Band gaps obtained using the hybrid functional HSE are in good agreement with experiment. The electronic densities of states are very similar for the different COFs (Supplementary Fig. ), suggesting similar charge carrier concentrations. We also calculated free energies of hydrogen adsorption, which are equivalent to the overpotentials for the HER within the computational hydrogen electrode model, using PBE+D3 (Supplementary Table ). They are similar for the different COFs, and small compared to the energy difference between the conduction band minimum and the potential required for hydrogen evolution. Thus, our calculations confirm that all of the investigated COFs are able to produce hydrogen. Spin densities of the HER intermediate (Fig. and Supplementary Fig. ) show that the transferred electron is located mostly at the quinoline group at which the hydrogen atom is adsorbed, its substituent, and the neighbouring phenyl group (bonded to the amine nitrogen). Altogether, the results suggest that the experimentally observed HER activity differences are not based on inherent reactivity differences as the backbone structure is mainly similar for all COFs, but rather from the functionality of the pending side group introduced by the Povarov reaction, which influences surface area and polarity/wettability of the pores. Using a polarizable continuum model, we confirmed that (electrostatic) solvation effects only weakly affect the results. Note that explicit solvation, which was not considered due to the high computational effort, could have a stronger effect (e.g., by hydrogen bonding).