Quantum computation is one of the most promising new paradigms for the simulation of physical systems composed of electrons and atomic nuclei, with applications in chemistry, solid-state physics, materials science, and molecular biology. This requires a truncated representation of the electronic structure Hamiltonian using a finite number of orbitals. While it is, in principle, obvious how to improve on the representation by including more orbitals, this is usually unfeasible in practice (e.g., because of the limited number of qubits available) and severely compromises the accuracy of the obtained results. Here, we propose a quantum algorithm that improves on the representation of the physical problem by virtue of second-order perturbation theory. In particular, our quantum algorithm evaluates the second-order energy correction through a series of time-evolution steps under the unperturbed Hamiltonian. An important application is to go beyond the active-space approximation, allowing to include corrections of virtual orbitals, known as multireference perturbation theory. Here, we exploit the fact that the unperturbed Hamiltonian is diagonal for virtual orbitals and show that the number of qubits is independent of the number of virtual orbitals. This gives rise to more accurate energy estimates without increasing the number of qubits. Moreover, we demonstrate numerically for realistic chemical systems that the total runtime has highly favorable scaling in the number of virtual orbitals compared to previous studies. Numerical calculations confirm the necessity of the multireference perturbation theory energy corrections to reach accurate ground-state energy estimates. Our perturbation theory quantum algorithm can also be applied to symmetry-adapted perturbation theory. As such, we demonstrate that perturbation theory can help to reduce the quantum hardware requirements for quantum chemistry. Published by the American Physical Society 2024