Although the numerical abilities of many vertebrate species have been investigated in the scientific literature, there are few convincing accounts of invertebrate numerical competence. Honeybees, Apis mellifera, by virtue of their other impressive cognitive feats, are a prime candidate for investigations of this nature. We therefore used the well-established delayed match-to-sample paradigm, to test the limits of honeybees' ability to match two visual patterns solely on the basis of the shared number of elements in the two patterns. Using a y-maze, we found that bees can not only differentiate between patterns containing two and three elements, but can also use this prior knowledge to differentiate three from four, without any additional training. However, bees trained on the two versus three task could not distinguish between higher numbers, such as four versus five, four versus six, or five versus six. Control experiments confirmed that the bees were not using cues such as the colour of the exact configuration of the visual elements, the combined area or edge length of the elements, or illusory contours formed by the elements. To our knowledge, this is the first report of number-based visual generalisation by an invertebrate.