Scientists call Fish Worms "nematodes." The species involved are usually "Terranova decipiens" or "Porrocaecum decipiens."
They are pests that infest the bodies of fish.
This infestation occurs naturally, and can't be prevented. They are parasites that live in both the stomach and flesh of the fish. They can grow up to 1 1/2 inches (4 cm) long, and be brown or cream-coloured.
This mostly occurs in fish in areas where there are seals, therefore most of the fish affected are fish that live near the shore. Cod are very affected, as well as flounder, haddock, herring, mackerel, Pacific rockfish, red snapper, salmon, sole and whiting.
The worms spend part of their life inside the stomachs of seals, where they lay their eggs. The eggs pass into the sea and hatch.
When fish are caught and filleted, the fillets can be inspected for these worms on a glass table with a light underneath. The process is called candling. Not all the worms are always caught. It is impossible to notice them all.
They are dangerous to consume. They can live in human stomachs as well as they can seal stomachs. They will inhabit the stomach and lower intestine.
The worms are killed by cooking, or by freezing down to -5 F (-20 C) for at least 24 hours.
So even if you do discover a worm in your cooked cod, as many do, it is safe to eat -- it's just that no one wants to.
The danger is in eating raw fish, in dishes such as sushi, sashimi and ceviche,
Many health authorities now require that fish used in Japanese raw fish dishes be frozen first.
This doesn't help, though, with dishes such as seared fish fillets that were never frozen, and left somewhat raw in the middle.