Blood-brain barrier:

a barrier between the brain itself and the blood supply of the brain, which prevents most substances from moving from the blood to brain tissue. Substances like glucose that are important to brain function are able to cross the blood-brain barrier, along a small collection of other substances like lipid-soluble molecules (e.g. psychoactive drugs). The blood-brain barrier plays a protective role, keeping potentially harmful substances from invading the brain.

Learn more:

Know your brain: Blood-brain barrier

2-Minute Neuroscience: Blood-brain barrier