On 17 August 2017, the Advanced LIGO1 and Virgo2 detectorsobserved the gravitational-wave event GW170817—a strong signalfrom the merger of a binary neutron-star system3. Less than twoseconds after the merger, a γ-ray burst (GRB 170817A) was detectedwithin a region of the sky consistent with the LIGO–Virgo-derivedlocation of the gravitational-wave source4–6. This sky region wassubsequently observed by optical astronomy facilities7, resultingin the identification8–13 of an optical transient signal withinabout ten arcseconds of the galaxy NGC 4993. This detection ofGW170817 in both gravitational waves and electromagnetic wavesrepresents the first ‘multi-messenger’ astronomical observation.Such observations enable GW170817 to be used as a ‘standardsiren’14–18 (meaning that the absolute distance to the source can bedetermined directly from the gravitational-wave measurements)to measure the Hubble constant. This quantity represents the localexpansion rate of the Universe, sets the overall scale of the Universeand is of fundamental importance to cosmology. Here we report ameasurement of the Hubble constant that combines the distanceto the source inferred purely from the gravitational-wave signalwith the recession velocity inferred from measurements of theredshift using the electromagnetic data. In contrast to previousmeasurements, ours does not require the use of a cosmic ‘distanceladder’19: the gravitational-wave analysis can be used to estimatethe luminosity distance out to cosmological scales directly, withoutthe use of intermediate astronomical distance measurements. Wedetermine the Hubble constant to be about 70 kilometres persecond per megaparsec. This value is consistent with existingmeasurements20,21, while being completely independent of them.Additional standard siren measurements from future gravitationalwavesources will enable the Hubble constant to be constrained tohigh precision.