  This paper is the first of a series dedicated to the X-ray properties of the
young open cluster NGC 6231. Our data set relies on an XMM-Newton campaign of a
nominal duration of 180 ks and reveals that NGC 6231 is very rich in the X-ray
domain too. Indeed, 610 X-ray sources are detected in the present field of
view, centered on the cluster core. The limiting sensitivity of our survey is
approximately 6E-15 erg/s/cm^2 but clearly depends on the location in the field
of view and on the source spectrum. Using different existing catalogues, over
85% of the X-ray sources could be associated with at least one optical and/or
infrared counterpart within a limited cross-correlation radius of 3 arcsec at
maximum. The surface density distribution of the X-ray sources presents a
slight N-S elongation. Once corrected for the spatial sensitivity variation of
the EPIC instruments, the radial profile of the source surface density is well
described by a King profile with a central density of about 8 sources per
arcmin^2 and a core radius close to 3.1arcmin. The distribution of the X-ray
sources seems closely related to the optical source distribution. The expected
number of foreground and background sources should represent about 9% of the
detected sources, thus strongly suggesting that most of the observed X-ray
emitters are physically belonging to NGC 6231. Finally, beside a few bright but
soft objects -- corresponding to the early-type stars of the cluster -- most of
the sources are relatively faint (~5E-15 erg/s/cm^2) with an energy
distribution peaked around 1.0-2.0 keV.
