Grit, a non-cognitive skill that indicates perseverance and passion for long-term goals, has been shown to predict academic achievement. This paper provides evidence that grit also predicts student outcomes during the challenging period of the Covid-19 pandemic. We use a unique dataset from a digital learning platform in the United Arab Emirates to construct a behavioral measure of grit. We find that controlling for baseline ability, students who were grittier according to this measure before the pandemic, register lower declines in math and science scores during the coronavirus period. Using machine learning, behavioral data in the platform prior to the pandemic can explain 77% of the variance in academic resilience. A survey measure of grit of the same students, on the other hand, does not have significant predictive power over performance changes. Our findings have implications for interventions on non-cognitive skills, as well as how data from digital learning platforms can be used to predict student behavior and outcomes, which we expect will be increasingly relevant as AI-based learning technologies become more common.