Foraging theory predicts that individuals should choose a prey that maximizes energy rewards relative to the energy expended to access, capture, and consume the prey. However, the relative roles of differences in the nutritive value of foods and costs associated with differences in prey accessibility are not always clear. Coral-feeding fishes are known to be highly selective feeders on particular coral genera or species and even different parts of individual coral colonies. The absence of strong correlations between the nutritional value of corals and prey preferences suggests other factors such as polyp accessibility may be important. Here, we investigated within-colony feeding selectivity by the corallivorous filefish, Oxymonacanthus longirostris, and if prey accessibility determines foraging patterns. After confirming that this fish primarily feeds on coral polyps, we examined whether fish show a preference for different parts of a common branching coral, Acropora nobilis, both in the field and in the laboratory experiments with simulated corals. We then experimentally tested whether nonuniform patterns of feeding on preferred coral species reflect structural differences between polyps. We found that O. longirostris exhibits nonuniform patterns of foraging in the field, selectively feeding midway along branches. On simulated corals, fish replicated this pattern when food accessibility was equal along the branch. However, when food access varied, fish consistently modified their foraging behavior, preferring to feed where food was most accessible. When foraging patterns were compared with coral morphology, fish preferred larger polyps and less skeletal protection. Our results highlight that patterns of interspecific and intraspecific selectivity can reflect coral morphology, with fish preferring corals or parts of coral colonies with structural characteristics that increase prey accessibility.