This paper introduces a procedure based on genetic programming to evolve XSLT programs (usually called stylesheets or logicsheets). XSLT is a general purpose, document-oriented functional language, generally used to transform XML documents or, in general, solve any problem that can be coded as an XML document. The proposed solution uses a tree representation for the stylesheets as well as diverse specific operators in order to obtain, in the studied cases and a reasonable time, a XSLT stylesheet that performs the transformation. Categories and Subject Descriptors I.2.2 [Computing Methodologies]: Artificial Intelligence - Automatic Programming; I.7 [Computing Methodologies]: Document and Text Processing General Terms Algorithms Keywords Stylesheets, XML, XSLT, Evolutionary Computation Techniques