  This paper studies averaging algebras, say, associative algebras endowed with
averaging operators. We develop a cohomology theory for averaging algebras and
justify it by interpreting lower degree cohomology groups as formal
deformations and abelian extensions of averaging algebras. We make explicit the
$L_\infty$-algebra structure over the cochain complex defining cohomology
groups and introduce the notion of homotopy averaging algebras as Maurer-Cartan
elements of this $L_\infty$-algebra.
