We report the results of an optical campaign carried out by the XMM-Newton Survey Science Centre with the specific goal of identifying the brightest X-ray sources in the XMM-Newton Galactic plane survey. In addition to photometric and spectroscopic observations obtained at the ESO-VLT and ESO-3.6 m, we used cross-correlations with the 2XMMi, USNO-B1.0, 2MASS, and GLIMPSE catalogues to advance the identification process. Active coronae account for 16 of the 30 positively or tentatively identified X-ray sources and exhibit the softest X-ray spectra. Many of the identified hard X-ray sources are associated with massive stars, possible members of binary systems and emitting at intermediate X-ray luminosities of 10 32−34 erg s −1 . Among these are (i) a very absorbed, likely hyper-luminous star with X-ray/optical spectra and luminosities comparable to those of η Carina; (ii) a new X-rayselected WN8 Wolf-Rayet star in which most of the X-ray emission probably arises from wind collision in a binary; (iii) a new Be/X-ray star belonging to the growing class of γ-Cas analogues; and (iv) a possible supergiant X-ray binary of the kind discovered recently by INTEGRAL. One of the sources, XGPS-25, has a counterpart of moderate optical luminosity that exhibits HeII λ4686 and Bowen CIII-NIII emission lines, suggesting that this may be a quiescent or X-ray shielded low mass X-ray binary, although its X-ray properties might also be consistent with a rare kind of cataclysmic variable (CV). We also report the discovery of three new CVs, one of which is a likely magnetic system displaying strong X-ray variability. The soft (0.4-2.0 keV) band log N(>S )−log S curve is completely dominated by active stars in the flux range of 1 × 10 −13 to 1 × 10 −14 erg cm −2 s −1 . Several active coronae are also detected above 2 keV suggesting that the population of RS CVn binaries contributes significantly to the hard X-ray source population. In total, we are able to identify a large fraction of the hard (2-10 keV) X-ray sources in the flux range of 1 × 10 −12 to 1 × 10 −13 erg cm −2 s −1 with Galactic objects at a rate consistent with what is expected for the Galactic contribution alone.