Thoroughly wash the fish heads and bones and remove the gills (gills would make the soup bitter).
Place them in a pot, add cold water, the whole unpeeled onion, carrot, bay leaf, and black peppercorns. Bring to a boil, reduce the heat, and simmer slowly for 30-40 minutes (letting it just barely bubble).
Regularly skim the foam from the surface to keep the broth clear. Strain the broth through a fine sieve or cheesecloth into a clean pot. Discard the onion and bones; you can set the carrot aside.