We describe a technique for inducing localized expression of genes fused to heat-shock gene promoters. We demonstrate that a localized heat-shock response can be induced in Drosophila melanogaster at any developmental stage after formation of the cellular blastoderm by contacting a region of the animal with a heated needle. The size of the induced region can be altered by varying parameters such as the temperature and size of the needle tip. The test system utilized here is a D. melanogaster strain transformed with a fusion of the Drosophila hsp26 gene and the E. coli lacZ gene; the activity of this hybrid gene is monitored in whole animals by staining for beta-galactosidase activity. Induced beta-galactosidase activity is confined to the cells in the region of heating; the beta-galactosidase activity can still be detected 48 hr after the heat shock. Given the heat inducibility of Drosophila heat-shock promoters in heterologous systems, we suggest that this technique will be useful for allowing spatially controlled induction of a gene of interest in any organism into which fusion genes can be introduced. Additional uses of the technique for following cell movements during development are discussed.