We propose a model in which agents with heterogeneous incomes decide whether to comply with shelter-in-place orders or gain additional income at the risk of getting the disease. There is a negative externality of non-compliance as the risk of catching COVID-19 is a function of the number of non-compliers. Drawing on evidence collected during the first months of the 2020 pandemic, we show theoretically that the level of compliance is higher in richer and more densely populated communities, and the effect of inequality on compliance is non-monotonic in the severity of pandemic. Slanted media affect compliance as well: if the media de-emphasizes the threat, compliance falls. At the same time, the demand for such media is higher among those who do not comply: although they beneﬁt from others complying because of negative externality, the slanted media are more informative for their individual decisions.