The expression of sacB, the Bacillus subtilis gene encoding levansucrase, is lethal to mycobacteria in the presence of 10% sucrose. In this study, we describe the use of sacB as a marker for positive selection of gene-replacement events into Mycobacterium smegmatis. A sucrose counter-selectable suicide plasmid was used to deliver an inactivated copy of the pyrF gene (pyrF::K(m)) into the M. smegmatis genome. Only uracil auxotroph clones, resulting from replacement of the endogenous pyrF allele, survived in a one-step selection on plates containing kanamycin and 10% sucrose. This demonstrated that selection on sucrose against the maintenance of the vector bearing the sacB gene is 100% efficient, enabling the positive selection of allelic-exchange mutants. Two-step selection is also feasible; it was used to construct unmarked pyrF mutants in which the gene was inactivated by a frameshift mutation. This method of generating unmarked, directed mutations is rapid and simple, making it a powerful tool for the genetic characterization of mycobacteria.