A spectrophotometer capable of high spectral resolution (e.g., in the GHz range) is presented. The spectrophotometer includes a container for holding a sample, an arrayed-waveguide grating coupled to the sample holder, and a detector array coupled to the arrayed-waveguide grating. The arrayed-waveguide grating may be a monolithic chip, and the container may be integrated into the chip. An integrated container may be a microfluidic channel formed through the layers in the chip and positioned in such a way that light is transferable from the microfluidic channel to the waveguides of the arrayed-waveguide grating.