Genome reduction has been observed in many bacterial lineages that have adapted to specialized environments. The extreme genome degradation seen for obligate pathogens and symbionts appears to be dominated by genetic drift. In contrast, for free-living organisms with reduced genomes, the dominant force is proposed to be direct selection for smaller, streamlined genomes. Most variation in gene content for these free-living species is of "accessory" genes, which are commonly gained as large chromosomal islands that are adaptive for specialized traits such as pathogenicity. It is generally unclear, however, whether the process of accessory gene loss is largely driven by drift or selection. Here we demonstrate that selection for gene loss, and not a shortened genome, per se, drove massive, rapid reduction of accessory genes. In just 1,500 generations of experimental evolution, 80% of populations of Methylobacterium extorquens AM1 experienced nearly parallel deletions removing up to 10% of the genome from a megaplasmid present in this strain. The absence of these deletion events in a mutation accumulation experiment suggested that selection, rather than drift, has dominated the process. Reconstructing these deletions confirmed that they were beneficial in their selective regimes, but led to decreased performance in alternative environments. These results indicate that selection can be crucial in eliminating unnecessary genes during the early stages of adaptation to a specialized environment.