Continuous in vitro evolution methods were used to study the behavior of an evolving population of RNA ligase ribozymes in response to selection pressures involving conditions of extreme pH. The starting population consisted of randomized variants of a ribozyme that had been optimized for activity at pH 8.5. The ribozymes were subjected to repeated rounds of selective amplification under progressively more acidic or more alkaline conditions. The two final evolved populations of ribozymes were able to operate at either pH 5.8 or pH 9.8, respectively. Representative individuals from the two final populations were isolated and characterized. The low-pH ribozyme exhibited a 10-fold increase in catalytic rate at pH 5.8 compared to the starting molecule. The high-pH ribozyme retained its structural integrity and activity at pH 9.8, whereas the starting molecule was denatured under this condition. These findings demonstrate that a population of functional macromolecules can adapt to stringent environmental conditions through the acquisition of relatively few mutations. The results establish continuous in vitro evolution as a useful model system for exploring the evolution of enzymatic function in extreme environments.