Nanophotonic structures can be used in solar cells for enhancing the absorption and collection of sunlight.