In [Dr1] Drinfeld showed that any finite dimensional Hopf algebra G extends to a quasitriangular Hopf algebra D(G), the quantum double of G. Based on the construction of a so-called diagonal crossed product developed by the authors in [HN], we generalize this result to the case of quasi-Hopf algebras G. As for ordinary Hopf algebras, as a vector space the "quasi-quantum double" D(G) is isomorphic to (G) over cap x G, where (G) over cap denotes the dual of G. We give explicit formulas for the product, the coproduct, the R-matrix and the antipode on D(G) and prove that they fulfill Drinfeld's axioms of a quasitriangular quasi-Hopf algebra. in particular D(G) becomes an associative algebra containing G = 1((G) over cap) x G as a quasi-Hopf subalgebra. On the other hand, (G) over cap = (G) over cap x 1(G) is not a subalgebra of D(G) unless the coproduct on G is strictly coassociative. It is shown that the category Rep D(G) of finite dimensional representations of D(G) coincides with what has been called the double category of G-modules by S. Majid [M2]. Thus our construction gives a concrete realization of Majid's abstract definition of quasi-quantum doubles in terms of a Tannaka-Krein-like reconstruction procedure. The whole construction is shown to generalize to weak quasi-Hopf algebras with D(G) now being linearly isomorphic to a subspace of (G) over cap x G.