The clusters of galaxies represent the last step of the formation of large scale structures in the Universe. They are both useful cosmological probes and unique astrophysical laboratories. The clusters grow by accretion of surrounding structures and from the merging of subclusters, in very energetic events, eventually forming a diffuse gas phase made of a hot thermal component, but also leading to particle acceleration up to very high energies.
After introducing the role of clusters in our understanding of the assembly of matter in the Universe, I will discuss how we can study the diffuse gas phase across cosmic time. The presentation will highlight results based on the NIKA/NIKA2 camera at the "Institute de Radio Astronomie Millimetrique" 30m telescope, sensitive to the thermal gas pressure via the Sunyaev-Zel'dovich effect. I will also present prospects for probing the non-thermal component in the gamma rays.