Context. Thanks to the large collecting area (3 × ∼1500 cm 2 at 1.5 keV) and wide field of view (30 across in full field mode) of the X-ray cameras on board the European Space Agency X-ray observatory XMM-Newton, each individual pointing can result in the detection of up to several hundred X-ray sources, most of which are newly discovered objects. Since XMM-Newton has now been in orbit for more than 15 yr, hundreds of thousands of sources have been detected. Aims. Recently, many improvements in the XMM-Newton data reduction algorithms have been made. These include enhanced source characterisation and reduced spurious source detections, refined astrometric precision of sources, greater net sensitivity for source detection, and the extraction of spectra and time series for fainter sources, both with better signal-to-noise. Thanks to these enhancements, the quality of the catalogue products has been much improved over earlier catalogues. Furthermore, almost 50% more observations are in the public domain compared to 2XMMi-DR3, allowing the XMM-Newton Survey Science Centre to produce a much larger and better quality X-ray source catalogue. Methods. The XMM-Newton Survey Science Centre has developed a pipeline to reduce the XMM-Newton data automatically. Using the latest version of this pipeline, along with better calibration, a new version of the catalogue has been produced, using XMM-Newton X-ray observations made public on or before 2013 December 31. Manual screening of all of the X-ray detections ensures the highest data quality. This catalogue is known as 3XMM. Results. In the latest release of the 3XMM catalogue, 3XMM-DR5, there are 565 962 X-ray detections comprising 396 910 unique X-ray sources. Spectra and lightcurves are provided for the 133 000 brightest sources. For all detections, the positions on the sky, a measure of the quality of the detection, and an evaluation of the X-ray variability is provided, along with the fluxes and count rates in 7 X-ray energy bands, the total 0.2-12 keV band counts, and four hardness ratios. With the aim of identifying the detections, a cross correlation with 228 catalogues of sources detected in all wavebands is also provided for each X-ray detection. Conclusions. 3XMM-DR5 is the largest X-ray source catalogue ever produced. Thanks to the large array of data products associated with each detection and each source, it is an excellent resource for finding new and extreme objects.Key words. catalogs -astronomical databases: miscellaneous -surveys -X-rays: general Based on observations obtained with XMM-Newton, an ESA science mission with instruments and contributions directly funded by ESA Member States and NASA.The catalogue is available at http://cdsarc.u-strasbg.fr/ viz-bin/VizieR?-meta.foot&-source=IX/46