Small bodies such as the near-Earth asteroid Bennu drift in their orbit due to thermal radiation forces (the Yarkovsky effect). Ground-based observations have indicated a nonzero probability of Bennu impacting Earth, depending on how its orbit evolves. Thus, among the goals of the OSIRIS-REx (Origins, Spectral Interpretation, Resource Identification, and Security-Regolith Explorer) mission to Bennu were to precisely measure the Yarkovsky effect and refine the impact hazard assessment for this body. Here we address these objectives. Using OSIRIS-REx spacecraft tracking data, we derive meter-level constraints on the distance between Earth and Bennu from January 2019 to October 2020. While these data greatly improve the knowledge of the trajectory of Bennu, they also require an unprecedented fidelity for the modeling of an asteroid's trajectory. In particular, special care is needed to take into account the contribution of 343 small-body perturbers and the uncertainty in their masses. Radiation effects such as the Poynting-Robertson drag, so far only considered for interplanetary dust dynamics, now become a consideration for modeling the trajectory of a 500-m asteroid such as Bennu. By employing a thermophysical model based on OSIRIS-REx's characterization of Bennu, we estimate a semimajor axis drift of - 284 . 6 ± 0 . 2 m/yr (signal-to-noise ratio ∼1400) at epoch 2011 January 1 caused by the Yarkovsky effect. The largest source of modeling error is solar wind drag, which may lower the magnitude of the semimajor axis drift from the Yarkovsky effect by up to 0.16 m/yr. The Yarkovsky-related semimajor axis drift varies by roughly ± 1 m/yr as the orbit of Bennu evolves due to planetary perturbations from 1900 to 2135. The Yarkovsky thermophysical model proves to be extremely accurate by predicting a bulk density estimate within 0.1% of that estimated through gravity science analysis. Compared to the information available before the OSIRIS-REx mission, the knowledge of the circumstances of the scattering Earth encounter that will occur in 2135 improves by a factor of 20, thus allowing us to rule out many previously possible impact trajectories. However, there remain some impact trajectories compatible with the data. Prior to the spacecraft encounter, the overall impact probability through 2200 was 3 . 7 × 10-4 (1 in 2700). As a result of our analysis, the cumulative impact probability through 2300 becomes 5 . 7 × 10-4 (1 in 1750) and the most significant individual impact solution is for September 2182, with an impact probability of 3 . 7 × 10-4 (1 in 2700). Both Bennu and (29075) 1950 DA have a Palermo scale value of - 1 . 42 and share the distinction as the currently most hazardous object in the asteroid catalog.