A deep learning algorithm using optical coherence tomography (OCT) images can predict visual impairment (Snellen VA 20/40 or worse) in retinitis pigmentosa with an area under the curve (AUC) of 0.87 in both internal and external testing. The algorithm performed best with OCT images alone, and combining infrared images did not improve performance. This provides proof-of-concept for using deep learning to estimate visual function from imaging, potentially aiding clinical trial screening and patient monitoring.