The interaction of electromagnetic waves with matter can be controlled by structuring the matter on the scale of the wavelength of light, and various photonic components have been made by structuring materials using top-down or bottom-up approaches. Dip-pen nanolithography is a scanning-probe-based fabrication technique that can be used to deposit materials on surfaces with high resolution and, when carried out in parallel, with high throughput. Here, we show that lyotropic optical diffraction gratings--composed of biofunctional lipid multilayers with controllable heights between approximately 5 and 100 nm--can be fabricated by lipid dip-pen nanolithography. Multiple materials can be simultaneously written into arbitrary patterns on pre-structured surfaces to generate complex structures and devices, allowing nanostructures to be interfaced by combinations of top-down and bottom-up fabrication methods. We also show that fluid and biocompatible lipid multilayer gratings allow label-free and specific detection of lipid-protein interactions in solution. This biosensing capability takes advantage of the adhesion properties of the phospholipid superstructures and the changes in the size and shape of the grating elements that take place in response to analyte binding.