GW170817 was the first gravitational wave detection of a binary neutron-star merger1. It was accompanied by radiation across the electromagnetic spectrum and localized2 to the galaxy NGC 4993 at a distance of 40 megaparsecs. It has been proposed that the observed γ-ray, X-ray and radio emission is due to an ultra-relativistic jet launched during the merger, directed away from our line of sight3–6. The presence of such a jet is predicted from models that posit neutron-star mergers as the central engines that drive short hard γ-ray bursts7,8. Here we report that the radio light curve of GW170817 has no direct signature of an off-axis jet afterglow. Although we cannot rule out the existence of a jet pointing elsewhere, the observed γ-rays could not have originated from such a jet. Instead, the radio data require a mildly relativistic wide-angle outflow moving towards us. This outflow could be the high-velocity tail of the neutron-rich material dynamically ejected during the merger or a cocoon of material that breaks out when a jet transfers its energy to the dynamical ejecta. The cocoon model explains the radio light curve of GW170817 as well as the γ-rays and X-rays (possibly also ultraviolet and optical emission)9–15, and is therefore the model most consistent with the observational data. Cocoons may be a ubiquitous phenomenon produced in neutron-star mergers, giving rise to a heretofore unidentified population of radio, ultraviolet, X-ray and γ-ray transients in the local Universe.