How does active transport differ from diffusion in terms of cell energy?

does not require any energy because it occurs down a concentration gradient. This means it goes from one side which has a high concentration of a particular molecule, to another side with a low concentration of this molecule. This is a passive act, requiring no energy input from the cell because it simply equalizes the concentrations of the molecules on both sides of a membrane. Simple ion channels are in place for diffusion, and the molecule diffuses to the less concentrated side simply and without the need for ATP being broken down for energy.

on the other hand, does exactly the opposite. Molecules to be actively transported will go from a side in which they are less concentrated to a side in which there is already a high concentration of them, so against the concentration gradient. This process requires energy- if you think of cramming more objects into an already stuffed room, more energy and force is needed to push them into that crowded space.

Active transport therefore requires energy in the form of ATP to be released for the transport to take place, and is usually mediated via special transport channels which bind the molecule and transport it to the other side, with the cost of ATP being broken down to release energy.

To visualize this: it is easier to go down a slide, than it is to climb up it. Molecules in diffusion slide down the slide to the other side, but have to be actively transported up the slide by a helper (transport channel), with energy.