This study compared the potential of an aqueous extract of an edible mushroom (Flammulina velutipes) to prevent melanosis in cultured Kuruma shrimp (Marsupenaeus japonicus) with other antimelanosic compounds in vivo. The mushroom extract contained 9.1 mg/mL ergothioneine (ESH). Immersion of live full-grown shrimp in a 0.5% w/v solution of mushroom extract significantly reduced PPO activity in shrimp hemolymph. In addition, expression of the prophenoloxidase (proPO) gene decreased in hemocytes, suggesting that the extract blocked the activation of the proPO cascade. Consequently, the development of melanosis in the treated shrimp was significantly suppressed during ice storage. Treatment with a 0.05% w/v solution of sodium ascorbate and 4-hexyl-1,3-benzenediol had the same effect. In vitro experiments showed that ESH effectively inhibited PPO activity and activation of the proPO cascade in hemocyte lysate supernatant. This study suggests that in vivo application of F. velutipes mushroom extract is an effective natural alternative to synthetic antimelanosic agents to inhibit postmortem melanosis in shrimp. Practical Application: The extract of an edible mushroom (F. velutipes) containing ergothioneine can be a promising natural alternative to synthetic antimelanosic agents used to prevent postharvest melanosis in shrimp and other crustaceans. Furthermore, utilization of the mushroom trimmings could also help address the growing concerns on the disposal of such agricultural wastes and instead use it into a novel purpose as a source of antimelanosic and antioxidants for food and industrial application.