We show that the octonions are a twisting of the group algebra of Z(2) x Z(
2) x Z(2) in the quasitensor category of representations of a quasi-Hopf al
gebra associated to a group 3-cocycle, In particular, we show that they are
quasialgebras associative up to a 3-cocycle isomorphism. We show that one
may make general constructions far quasialgebras exactly along the lines of
the associative theory, including quasilinear algebra, representation theo
ry, and an automorphism quasi-Hopf algebra. We study the algebraic properti
es of quasialgebras of the type which includes the octonions. Further examp
les include the higher 2(n)-onion Cayley algebras and examples associated t
o Hadamard matrices. (C) 1999 Academic Press.