Foragers that feed on hidden prey are uncertain about the intake rate they can achieve as they enter a patch. However, foraging success can inform them, especially if they have prior knowledge about the patch quality distribution in their environment. We experimentally tested whether and how red knots (Calidris canutus) use such information and whether their patch-leaving decisions maximized their long-term net energy intake rate. The results suggest that the birds combined patch sample information with prior knowledge by making use of the potential value assessment rule. We reject five alternative leaving rules. The potential encounter rate that the birds choose as their critical departure threshold maximized their foraging gain ratio (a modified form of efficiency) while foraging. The high experimental intake rates were constrained by rate of digestion. Under such conditions, maximization of the foraging gain ratio during foraging maximizes net intake rate during total time (foraging time plus digestive breaks). We conclude that molluscivore red knots, in the face of a digestive constraint, are able to combine prior environmental knowledge about patch quality with patch sample information to obtain the highest possible net intake over total time.