The "particle in a box" problem is investigated for a relativistic particle obeying the Klein-Gordon equation. To find the bound states, the standard methods known from elementary non-relativistic quantum mechanics can only be employed for "shallow" wells. For deeper wells, when the confining potentials become supercritical, we show that a method based on a scattering expansion accounts for Klein tunneling (undamped propagation outside the well) and the Klein paradox (charge density increase inside the well). We will see that in the infinite well limit, the wavefunction outside the well vanishes and Klein tunneling is suppressed: quantization is thus recovered, similarly to the non-relativistic particle in a box. In addition, we show how wavepackets can be constructed semianalytically from the scattering expansion, accounting for the dynamics of Klein tunneling in a physically intuitive way.