Predation risk is high for the many small coral reef fishes, requiring successful sheltering or other predator defence mechanisms. Coral-dwelling gobies of the genus Gobiodon live in close association with scleractinian corals of the genus Acropora. Earlier studies indicated that the low movement frequency of adult fishes and the development of skin toxins (crinotoxicity) are predation avoidance mechanisms. Although past experiments showed that predators refuse food prepared with goby skin mucus, direct predator–prey interactions have not been studied. The present study compares the toxicity levels of two crinotoxic coral gobies – Gobiodon histrio, representative of a conspicuously coloured species, and Gobiodon sp.3 with cryptic coloration – using a standard bioassay method. The results show that toxin levels of both species differ significantly shortly after mucus release but become similar over time. Predator preferences were tested experimentally in an aquarium in which the two gobies and a juvenile damselfish Chromis viridis were exposed to the small grouper Epinephelus fasciatus. Video-analysis revealed that although coral gobies are potential prey, E. fasciatus clearly preferred the non-toxic control fish (C. viridis) over Gobiodon. When targeting a goby, the predator did not prefer one species over the other. Contrary to our expectations that toxic gobies are generally avoided, gobies were often captured, but they were expelled quickly, repeatedly and alive. This unusual post-capture avoidance confirms that these gobies have a very good chance of surviving attacks in the field due to their skin toxins. Nonetheless, some gobies were consumed: the coral shelter may therefore also provide additional protection, with toxins protecting them mainly during movement between corals. In summary, chemical deterrence by crinotoxic fishes seems to be far more efficient in predation avoidance than in physical deterrence involving body squamation and/or strong fin spines.