  The detection of an electromagnetic counterpart (GRB 170817A) to the
gravitational wave signal (GW170817) from the merger of two neutron stars opens
a completely new arena for testing theories of gravity. We show that this
measurement allows us to place stringent constraints on general scalar-tensor
and vector-tensor theories, while allowing us to place an independent bound on
the graviton mass in bimetric theories of gravity. These constraints severely
reduce the viable range of cosmological models that have been proposed as
alternatives to general relativistic cosmology.
