Quantum field theory in curved spacetimes suffers in general from an infinite ambiguity in the choice of Fock representation and associated vacuum. In cosmological backgrounds, the requirement of a unitary implementation of the field dynamics in the physical Hilbert space of the theory is a good criterion to ameliorate such ambiguity. Indeed, this criterion, together with a unitary implementation of the symmetries of the equations of motion, leads to a unique equivalence class of Fock representations. In this work, we apply the procedure developed for fields in cosmological settings to analyze the quantization of a scalar field in the presence of an external electromagnetic classical field in a flat background. We find a natural Fock representation that admits a unitary implementation of the quantum field dynamics. It automatically allows to define a particle number density at all times in the evolution with the correct asymptotic behavior, when the electric field vanishes. Moreover we show the unitary equivalence of all the quantizations that fulfill our criteria. Although we perform the field quantization in a specific gauge, we also show the equivalence between the procedures taken in different gauges.