In many Western countries, citizens have become increasingly biased in how they evaluate others based on political affiliation, and this affective polarization harms the functioning of governments. In an online experiment, we find that priming Americans with the threat of Russia’s invasion of Ukraine reduces affective polarization as measured by feeling thermometers. The effect is not significantly different when subjects are also primed with cross-party disagreement about how well President Biden is handling the conflict. Using an incentivized coordination game, we then show that feeling thermometers are behaviorally relevant as they predict subjects’ ability to coordinate and willingness to compromise. Our findings have great implications for society. While affective polarization undermines cooperation, citizens may come together when perceiving an external threat, regardless of perceived cross-party disagreement.