Very energetic astrophysical events are required to accelerate cosmic rays to above 10(18) electronvolts. GRBs (γ-ray bursts) have been proposed as possible candidate sources. In the GRB 'fireball' model, cosmic-ray acceleration should be accompanied by neutrinos produced in the decay of charged pions created in interactions between the high-energy cosmic-ray protons and γ-rays. Previous searches for such neutrinos found none, but the constraints were weak because the sensitivity was at best approximately equal to the predicted flux. Here we report an upper limit on the flux of energetic neutrinos associated with GRBs that is at least a factor of 3.7 below the predictions. This implies either that GRBs are not the only sources of cosmic rays with energies exceeding 10(18) electronvolts or that the efficiency of neutrino production is much lower than has been predicted.