The electronic properties and the function of hybrid inorganic-organic systems (HIOS) are intimately linked to their interface geometry. Here we show that the inclusion of the many-body collective response of the substrate electrons inside the inorganic bulk enables us to reliably predict the HIOS geometries and energies. This is achieved by the combination of dispersion-corrected density-functional theory (the DFT+ van~der~Waals approach) [Phys. Rev. Lett. 102, 073005 (2009)], with the Lifshitz-Zaremba-Kohn theory for the nonlocal Coulomb screening within the bulk. Our method yields geometries in remarkable agreement ($\approx${}0.1\,\,\AA{}) with normal incidence x-ray standing wave measurements for the 3, 4, 9, 10-perylene-tetracarboxylic acid dianhydride (C24O6H8, PTCDA) molecule on Cu(111), Ag(111), and Au(111) surfaces. Similarly accurate results are obtained for xenon and benzene adsorbed on metal surfaces.
The energetics at the interfaces between metal and monolayers of covalently bound organic molecules is studied theoretically. Despite the molecules under consideration displaying very different frontier orbital energies, the highest occupied molecular levels are found to be pinned at a constant energy offset with respect to the metal Fermi level. In contrast, the molecular properties strongly impact the metal work function. These interfacial phenomena are rationalized in terms of charge fluctuations and electrostatics at the atomic length scale as determined by first-principles calculations.