Numerical discrimination is widespread in vertebrates, but this capacity varies enormously between the different species examined. The guppy (Poecilia reticulata), the only teleost examined following procedures that allow a comparison with the other vertebrates, outperforms amphibians, reptiles and many warm-blooded vertebrates, but it is unclear whether this is a feature shared with the other teleosts or represents a peculiarity of this species. We trained zebrafish (Danio rerio) to discriminate between numbers differing by one unit, varying task difficulty from 2 versus 3 to 5 versus 6 items. Non-numerical variables that covary with number, such as density or area, did not affect performance. Most fish reached learning criterion on all tasks up to 4 versus 5 discrimination with no sex difference in accuracy. Although no individual reached learning criterion in the 5 versus 6 task, performance was significant at the group level, suggesting that this may represent the discrimination threshold for zebrafish. Numerosity discrimination abilities of zebrafish compare to those of guppy, being higher than in some warm-blooded vertebrates, such as dogs, horses and domestic fowl, though lower than in parrots, corvids and primates. Learning rate was similar in a control group trained to discriminate between different-sized shapes, but zebrafish were slightly more accurate when discriminating areas than numbers and males were more accurate than females. At the end of the experiment, fish trained on numbers and controls trained on areas generalized to the reciprocal set of stimuli, indicating they had used a relational strategy to solve these tasks.