This dissertation deals with the fabrication of integrated spectrometers for use in miniaturized chemical analysis systems, also called 'lab-on-a-chip'-systems. The spectrometers are based on concave re ection gratings, and are fabricated in the epoxy-based material SU-8 by means of photolithography. Successful fabrication of re ection gratings requires a high degree of precision in the photolithographic process. The fabrication process has thus been optimized by optimizing the photolithographic process for fabrication of high aspect ratio structures, i.e. structures with details that are small compared to the height of the structure. A decisive factor is the ability of the process to separate closely- spaced structures. The primary measure of quality is thus the aspect ratio of the narrowest trench which it is possible to resolve in the lithographic process. The optimization of the photolithographic SU-8 fabrication process has caused the aspect ratio of the narrowest resolvable trench to rise from approximately 6 to 11.4. Simultaneously, the optimized process eliminates all problems regarding cracks in the fabricated structures. If the fabrication of the re ection grating is not perfect, this will primarily be re ected in the spectrometer as an increased transmission loss. The improved precision of the photolithographic process has caused the transmission loss of the fabricated spectrometers to decrease by a factor of six. This means that the spectrometer loss at this point only is two times higher than the predicted loss of a perfectly fabricated spectrometer.