A generalisation of Kurepa's inequality in inner product spaces that extends in its turn the de Bruijn refinement of the Cauchy--Buniakovsky-Schwarz inequality for sequences of real and complex numbers is given.