What is the difference between an EU regulation and an EU directive?

A regulation of the European Union is a legal act of the European Union with general validity and direct effect in the Member States. Regulations do not have to be transposed into national law by the EU Member States. Modifications of their provisions by the individual Member States are not possible.
In contrast to regulations, European Union directives are not directly effective and binding, but must instead be implemented by national legislation in order to become effective.
It is left to the individual Member States to decide how to implement directives. When implementing directives, they therefore have a certain amount of leeway.

[GMP Compliance Adviser, Chapter 21.A]