Free-stream perturbations induce large coherent structures, crucial to the laminar–turbulent transition on flight vehicles and turbine blades, significantly affecting drag, heat transfer, noise, etc. This paper computes the optimal free-stream perturbations that undergo the strongest amplification using an adjoint method, specifically for the incompressible flow around a NACA0012 airfoil, in contrast to sharp (or no) leading-edge configurations. These perturbations are examined at different angles of attack (0
$^{\circ }$–
$6^{\circ }$) and Reynolds numbers (
${\textit{Re}} = 1000$–
$8000$). At low angles of attack, two extreme points of energy growth emerge in the frequency–spanwise wavenumber plane, both on the axes. One has a spanwise wavenumber of zero, corresponding to two-dimensional unsteady modes in the wake, and the other has a frequency of zero, representing three-dimensional steady boundary-layer modes. The former is driven by the inflection point of the base velocity profile in the wake and is stronger, whereas the latter is related to the lift-up non-modal stability mechanism and directly influences the flow on the airfoil surfaces. The distribution of the three-dimensional steady optimal perturbations, similarly to the thickness of the base flow boundary layer, follows a
${\textit{Re}}^{-0.5}$ scaling law. This scaling enables the projection of optimal profiles obtained at low
${\textit{Re}}$ to high ones for engineering applications, where the direct calculation is prohibitively expensive. Subsequently, the linear optimal perturbation at
${\textit{Re}} = 100\,000$ is obtained, and the generation, nonlinear deformation and breakdown of streaks are examined by direct numerical simulation to illustrate the impact of the inflow perturbations on transition.