We investigate the mechanisms of lithium diffusion in layered intercalation compounds from first-principles. We focus on Li x CoO2 and find that lithium diffusion in this compound occurs predominantly with a divacancy mechanism. First-principles calculations predict that the activation barrier is very sensitive to the lithium concentration due to the strongly varying c-lattice parameter of the host and the change in effective valence of the cobalt ions. This translates into a diffusion coefficient that varies by several orders of magnitude with state of charge.