We develop a complete Dirac-Hartree-Fock-Bogoliubov approximation to the gr
ound state wave function and energy of finite nuclei. We apply it to spin-z
ero proton-proton and neutron-neutron pairing within the Dirac-Hartree-Bogo
liubov approximation (we neglect the Fock term), using a zero-range approxi
mation to the relativistic pairing tensor. We study the effects of the pair
ing on the properties of the even-even nuclei of the isotopic chains of Ca,
Ni, and Sn (spherical) and Kr and Sr (deformed), as well as the N=28 isoto
nic chain, and compare our results with experimental data and with other re
cent calculations.