Resonant waveguide gratings (RWGs), also known as guided mode resonant (GMR) gratings or waveguide-mode resonant gratings, are dielectric structures where these resonant diffractive elements benefit from lateral leaky guided modes and can operate from UV to microwave frequencies, in many different configurations. Some of the guided light is diffracted out of the guide while propagating, coupled back to radiation and interferes with the non-coupled reflected or transmitted waves. This leads to a very high reflection or transmission, giving rise to a Fano or Lorentzian-like lineshape profile at the zeroth order. RWGs are intrinsically very sensitive to angle and wavelength variations, being therefore effective filtering structures, especially for collimated light. Thanks to their high degree of optical tunability (wavelength, phase, polarization, intensity) and the variety of fabrication processes and materials available, RWGs have been implemented in a broad scope of applications in research and industry, such as optical security features, refractive index and fluorescence biosensors, spectrometers and optical couplers. This thesis describes the development and realization of color-selective diffraction devices using RWGs. The properties of paired impedance matched RWGs with finite size and different grating periods, but sharing the same substrate and coated waveguide, are first investigated. In particular, a specific wavelength range is in-coupled inside the waveguide by the first grating from a white incident light beam, and out-coupled from the second grating at a different angle. Periodic arrays of such paired RWGs allow achieving color-selective diffraction. Moreover, specific design methods based on confocal prolate spheroids are derived and used to generate surfaces with different grating periods and orientations, which can filter a specific spectral portion of a point source and to redirect and focus it to another point in space, viz. the observation point. This patterning is particularly beneficial in applications where light re-focusing is required, such as optical security or optical combiners for near-eye displays. Realizations as optical security labels through smartphone-based authentication are presented and discussed. Since the fabrication of such devices is extremely demanding, a fabrication method is developed to reduce the exposure time for the electron beam lithography. This method is beneficial to efficiently fabricate gratings with different periods and oriented at different angles. In particular, a pre-fracturing of the grating lines in one or more smaller stripes, depending on the grating period, is first implemented, followed by the fracturing using a beam step size smaller than the beam diameter. In the last part, optical structures comprising a metallic layer and a dielectric layer on a corrugated glass substrate are described. In essence, the hybridization of plasmon and waveguide modes is studied and used to design a color-selective optical coupler where the hybridized modes are leaking into the substrate at the first diffraction order and are coupled as guided mode. Such coupler may be used as dispersive element when the white light source is divergent allowing, for example, the realization of inexpensive, compact and robust spectrometers.