This article demonstrates a method for the fabrication of patterned surfaces using hairpin oligonucleotides carrying a novel photolabile group at the apex of the loop. Photolysis of surfaces carrying photolabile hairpin oligonucleotides results in the formation of areas carrying single-stranded DNA sequences that direct the deposition of the complementary sequence at the photolysed sites. The non-photolysed areas carrying the intact hairpin do not bind to complementary sequences due to the presence of the more stable intramolecular hairpin duplex. The photolithographic process was performed on silicon wafers and followed by atomic force microscopy and epi-fluorescent microscopy. The method described offers an attractive option for the fabrication of biologically interfaced patterned surfaces with specific recognition properties with potential uses in electronics and as biosensors.