  We define derived Poincar\'e--Birkhoff--Witt maps of dg operads or derived
PBW maps, for short, which extend the definition of PBW maps between operads of
V.~Dotsenko and the second author in 1804.06485, with the purpose of studying
the universal enveloping algebra of dg Lie algebras as a functor on the
homotopy category. Our main result shows that the map from the homotopy Lie
operad to the homotopy associative operad is derived PBW, which gives us an
amenable description of the homology of the universal envelope of an
$L_\infty$-algebra in the sense of Lada--Markl. We deduce from this several
known results involving universal envelopes of $L_\infty$-algebras of V.
Baranovsky and J. Moreno-Fern\'andez, and extend D. Quillen's classical
quasi-isomorphism $\mathcal C \longrightarrow BU$ from dg Lie algebras to
$L_\infty$-algebras; this confirms a conjecture of J. Moreno-Fern\'andez.
