In situ near edge X-ray absorption fine structure spectroscopy directly probes unoccupied states associated with backbonding interactions between the open metal site in a metal–organic framework and various small molecule guests.