Efficiency analysis is used for assessing links between technical efficiency (TE) of livestock farms and animal diseases. However, previous studies often do not make the link with the allocation of inputs and mainly present average effects that ignore the often huge differences among farms. In this paper, we studied the relationship between exposure to gastrointestinal (GI) nematode infections, the TE and the input allocation on dairy farms. Although the traditional cost allocative efficiency (CAE) indicator adequately measures how a given input allocation differs from the cost-minimising input allocation, they do not represent the unique input allocation of farms. Similar CAE scores may be obtained for farms with different input allocations. Therefore, we propose an adjusted allocative efficiency index (AAEI) to measure the unique input allocation of farms. Combining this AAEI with the TE score allows determining the unique input-output position of each farm. The method is illustrated by estimating efficiency scores using data envelopment analysis (DEA) on a sample of 152 dairy farms in Flanders for which both accountancy and parasitic monitoring data were available. Three groups of farms with a different input-output position can be distinguished based on cluster analysis: (1) technically inefficient farms, with a relatively low use of concentrates per 100 l milk and a high exposure to infection, (2) farms with an intermediate TE, relatively high use of concentrates per 100 l milk and a low exposure to infection, (3) farms with the highest TE, relatively low roughage use per 100 l milk and a relatively high exposure to infection. Correlation analysis indicates for each group how the level of exposure to GI nematodes is associated or not with improved economic performance. The results suggest that improving both the economic performance and exposure to infection seems only of interest for highly TE farms. The findings indicate that current farm recommendations regarding GI nematode infections could be improved by also accounting for the allocation of inputs on the farm.