Terraria item ID 2895. Terraria 1.4.5.7.
The Gold Worm is a critter. It is a golden recolor of the ordinary Worm, with a 1/400 (0.25%) chance of spawning in place of the ordinary version. The Gold Worm has only 5 health and no defense, and can be damaged by other enemies and players. The Gold Worm can be caught with any Bug Net to be carried around in the inventory and released later, or crafted into animated decorative furniture (Gold Worm Cage). Once crafted, the Gold Worm cannot be released again, unless the furniture item is de-crafted via Shimmer. The Gold Worm itself or the crafted furniture can be sold for 10 Gold.
Description from the Terraria Wiki.