Riboswitches are structured elements typically found in the 5' untranslated regions of mRNAs, where they regulate gene expression by binding to small metabolites. In all examples studied to date, these RNA control elements do not require the involvement of protein factors for metabolite binding. Riboswitches appear to be pervasive in eubacteria, suggesting that this form of regulation is an important mechanism by which metabolic genes are controlled. Recently discovered riboswitch classes have surprisingly complex mechanisms for regulating gene expression and new high-resolution structural models of these RNAs provide insight into the molecular details of metabolite recognition by natural RNA aptamers.