Semibounded symmetric operators have a distinguished self-adjoint extension, the Friedrichs extension. The eigenvalues of the Friedrichs extension are given by a variational principle that involves only the domain of the symmetric operator. Although Dirac operators describing relativistic particles are not semibounded, the Dirac operator with Coulomb potential is known to have a distinguished extension. Similarly, for Dirac-type operators on manifolds with a boundary a distinguished self-adjoint extension is characterised by the Atiyah-Patodi-Singer boundary condition. In this paper we relate these extensions to a generalisation of the Friedrichs extension to the setting of operators satisfying a gap condition. In addition we prove, in the general setting, that the eigenvalues of this extension are also given by a variational principle that involves only the domain of the symmetric operator.for k ≥ 1 are the discrete spectrum of A F in the interval (−∞, sup k≥1 λ k ), counted with multiplicities d k := # {j ≥ 1 : λ j = λ k } 2010 Mathematics Subject Classification. 49R05, 49S05, 47B25, 81Q10.