  Heavy quarks are a powerful probe for investigating the properties of the
Quark-Gluon Plasma created in heavy-ion collisions, since they are produced in
initial hard scattering processes and experience all the stages of the medium
evolution. ALICE has measured the production of $\mathrm{D}^0$, $\mathrm{D}^+$,
$\mathrm{D}^{*+}$, and $\mathrm{D}_{\mathrm{s}}^+$ mesons at central rapidity
in their hadronic decay channels in various collision systems and energies. We
present recent results for D-meson production measured by the ALICE
Collaboration in pp collisions at $\sqrt{s}=7$ and 2.76 TeV, Pb-Pb collisions
at $\sqrt{s_\mathrm{NN}}=2.76$ TeV and p-Pb collisions at
$\sqrt{s_\mathrm{NN}}=5.02$ TeV.
