In the present article, we show how to formulate the partially contracted n-electron valence second-order perturbation theory (NEVPT2) energies in the atomic and active molecular orbital basis by employing the Laplace transformation of orbital-energy denominators (OEDs). As atomic-orbital (AO) basis functions are inherently localized and the number of active orbitals is comparatively small, our formulation is particularly suited for a linearly scaling NEVPT2 implementation. In our formulation, there are two kinds of NEVPT2 energy contributions, which differ in the number of active orbitals in the two-electron integrals involved. Those involving integrals with either no or a single active orbital can be formulated completely in the AO basis as single-reference second-order Møller–Plesset perturbation theory and benefit from sparse active pseudo-density matrices—particularly if the active molecular orbitals are localized only in parts of a molecule. Conversely, energy contributions involving integrals with either two or three active orbitals can be obtained from Coulomb and exchange matrices generalized for pairs of active orbitals. Moreover, we demonstrate that Laplace-transformed partially contracted NEVPT2 is nothing less than time-dependent NEVPT2 [A. Y. Sokolov and G. K.-L. Chan, J. Chem. Phys. 144, 064102 (2016)] iff the all-active intermediates are computed with the internal-contraction approximation. Furthermore, we show that for multi-reference perturbation theories it is particularly challenging to find optimal parameters of the numerical Laplace transformation as the fit range may vary among the 8 different OEDs by many orders of magnitude. Selecting the number of quadrature points for each OED separately according to an accuracy-based criterion allows us to control the errors in the NEVPT2 energies reliably.