NO SUGAR AND SOLT.
There are more food which is dangerous to hermit crab than isn't. So becareful these things : Hermit crabs are polyphagia. You can give them even seeds of plants. But don't give them herb or herb seed. Pungent food, processed food isn't good for them, too.
+) They like coconut and mealworm.
I have two hermit crabs as a pet. So if you need more advice, please contact to firstname.lastname@example.org
Hermit crabs have soft, unarmored abdomens that they protect by occupying and carrying the empty shells of other animals such as snails. Hermit crabs are not picky eaters. They will eat a variety of foods, including algae, earthworms, fish, fresh shrimp, scallops, beef heart, brine shrimp, flake food, tube food, and almost all other commercially prepared foods. Live, fresh, frozen, dry, or freeze-dried, it makes no difference. A hermit crab may be fed two to three times a week; however, be careful not to overfeed or underfeed it.
Pieces of meat, such as thawed shrimp, scallops, or beef heart, may be soaked in a liquid vitamin complex and presented to the crab on the end of a toothpick. Algae, which is a part of the crab's diet in the wild, may be grown in a separate container with a few small pieces of coral or ordinary shells on the bottom. Within a few weeks, the shells will be covered with algae and may be placed in the display tank for the crabs to pick clean. Fresh spinach and lettuce may be used as a substitute for algae.
Source: Giwojna, Pete. Marine Hermit Crabs, pp. 115-17.