Production and secretion of a 28,172 Da hydrolase from Thermobifida fusca (TFH) in Bacillus megaterium MS941 and WH323 was investigated in shake flask and pH controlled bioreactors. Successful production of heterologous TFH was achieved by adapting the original tfh gene to the optimal codon usage of B. megaterium. A codon adaption index close to one was reached. The codon optimized tfh was cloned into an open reading frame with DNA sequence for the N-terminal signal peptide of B. megaterium lipase A and a C-terminal His6-tag, all under the control of a xylose inducible promoter. Successful TFH production and secretion were observed using batch reactor cultivations with complex medium. Expression of the tfh gene from the PxylA promoter and secretion of produced TFH were compared in detail to batch reactor cultivations with semi-defined growth medium. For the first time, significant TFH secretion was achieved using a semi-defined medium in glucose limited fed batch cultivations yielding 10-fold higher cell densities compared to LB medium cultivation. Comparable volumetric TFH activities were obtained for both cultivation strategies. Surprisingly, measured specific TFH activities exhibited drastic discrepancies between preparations from LB and semi-defined medium grown B. megaterium. TFH recovery by Ni-chelate affinity chromatography resulted in higher purification factors when LB medium was used. These results indicated that secreted TFH is favorably produced by batch cultures of B. megaterium WH323 in LB medium. Biotechnol. Bioeng. 2007;96:780–794. © 2006 Wiley Periodicals, Inc.