Earthworms are hermaphrodites.

Mature individuals posses both male and female gonads; but each individual needs to find a partner to exchange sperm.