Neutron stars are composed of the densest form of matter known to exist in our universe, and thus provide a unique laboratory for exploring the properties of cold matter at super-nuclear density. Measurements of the masses or radii of these objects can strongly constrain the neutron-star matter equation of state, and consequently the interior composition of neutron stars. Neutron stars that are visible as millisecond radio pulsars are especially useful in this respect, as timing observations of the radio pulses provide an extremely precise probe of both the pulsar's motion and the surrounding space-time metric. In particular, for a pulsar in a binary system, detection of the general relativistic Shapiro delay allows us to infer the masses of both the neutron star and its binary companion to high precision. Here we present radio timing observations of the binary millisecond pulsar PSR J1614-2230, which show a strong Shapiro delay signature. The implied pulsar mass of 1.97 +/- 0.04 M_sun is by far the highest yet measured with such certainty, and effectively rules out the presence of hyperons, bosons, or free quarks at densities comparable to the nuclear saturation density.