Dioecy is a plant mating system in which individuals of a species are either male or female. Although many flowering plants evolved independently from hermaphroditism to dioecy, the molecular mechanism underlying this transition remains largely unknown. Sex determination in the dioecious plant Asparagus officinalis is controlled by X and Y chromosomes; the male and female karyotypes are XY and XX, respectively. Transcriptome analysis of A. officinalis buds showed that a MYB-like gene, Male Specific Expression 1 (MSE1), is specifically expressed in males. MSE1 exhibits tight linkage with the Y chromosome, specific expression in early anther development and loss of function on the X chromosome. Knockout of the MSE1 orthologue in Arabidopsis induces male sterility. Thus, MSE1 acts in sex determination in A. officinalis.