Before Robert Hooke observed them through microscopes (around 1665), people apparently thought that fleas and mosquitoes bite because they hate us. Hooke wrote of his observations:
One of these Gnats I have suffer'd to pierce the skin of my hand, with its proboscis, and thence to draw out as much blood as to fill its belly as full as it could hold, making it appear very red and transparent; and this without any further pain, then whilst it was sinking in its proboscis, as it is also in the stinging of Fleas: a good argument, that these creatures do not wound the skin, and suck the blood out of enmity and revenge, but for meer necessity, and to satisfy their hunger.