Raman and micro-Raman analysis methods have been extensively investigated for the study of materials used in electronic and photonic devices. Raman studies are used to understand fundamental phonon properties, along with effects related to the crystal structure, disorder, doping, and external factors such as temperature and stress. Micro-Raman extends these investigations to the micron scale. This article reviews diverse benefits of Raman measurements when carried out using laser excitation in the near-ultraviolet wavelength range, nominally 400 to 325 nm. Micro-Raman methods in the near ultraviolet exploit the key advantage of reduced focal spot size, achievable at shorter wavelengths when using diffraction-limited optics, for mapping with high spatial resolution. There are distinct advantages common to Raman and micro-Raman spectroscopy in the near ultraviolet when compared to the widely used visible excitation. One advantage exploits the shallower optical penetration depth in select materials for probing near-surface regions or interfaces. A second advantage is related to tuning of the excitation photon energy relative to the electronic levels of a material for investigating resonance effects. Finally, the application of Raman scattering to materials which exhibit strong fluorescence requires tuning to a wavelength range away from the potentially obscuring emission. This article overviews several examples of these key advantages to study diverse applied physics problems in electronic and photonic materials. Topics covered include stress mapping in silicon and related materials, stress and thermal effects in gallium nitride and other group-III-nitride semiconductors, and carbon materials ranging from graphite and graphene to diamond grown using chemical vapor deposition. The fundamental effects of stress- and temperature-induced shifts in phonon energies and their application to study epitaxy and device-related effects are also briefly reviewed.