Background: Dodecin prevents riboflavin from autodegradation and exerting photo-induced cellular stress. Results: Ultrafast depopulation of excited states and ground state recovery is observed by transient spectroscopy. Conclusion: Ultrafast electron transfer in combination with proton transfer is responsible for deactivation of flavin excited states. Significance: A comprehensive study of parameters in the binding pocket affecting the riboflavin quenching mechanism is given.