How can I stop loading external images in Mail.app?

Mail.app > Preferences > Viewing > uncheck "Load remote content in messages"

Viewing Preferences

You will then have this banner at the top of each message that contains remote content (just in case you do want to see the images): load remote content button

Aside: I still see the occasional image in a message when looking through my spam folder. As best I can tell when I "view raw source" the spammers are including the image in the message text itself (there is a large block of text that looks like gibberish to me), but I'm not an expert on what is going on there. It might just be a bug in this feature.