We describe the science case, design and expected performances of the X/Gamma-ray Imaging Spectrometer (XGIS), a GRB and transients monitor developed and studied for the THESEUS mission project, capable of covering an exceptionally wide energy band (2 keV -10 MeV), with imaging capabilities and location accuracy <15 arcmin up to 150 keV over a Field of View of 2sr, a few hundreds eV energy resolution in the X-ray band (<30 keV) and few micro seconds time resolution over the whole energy band. Thanks to a design based on a modular approach, the XGIS can be easily re-scaled and adapted for fitting the available resources and specific scientific objectives of future high-energy astrophysics missions, and especially those aimed at fully exploiting GRBs and high-energy transients for multimessenger astrophysics and fundamental physics.