To compare microbial functional diversity in different oil-contaminated fields and to know the effects of oil contaminant and environmental factors, soil samples were taken from typical oil-contaminated fields located in five geographic regions of China. GeoChip, a high-throughput functional gene array, was used to evaluate the microbial functional genes involved in contaminant degradation and in other major biogeochemical/metabolic processes. Our results indicated that the overall microbial community structures were distinct in each oil-contaminated field, and samples were clustered by geographic locations. The organic contaminant degradation genes were most abundant in all samples and presented a similar pattern under oil contaminant stress among the five fields. In addition, alkane and aromatic hydrocarbon degradation genes such as monooxygenase and dioxygenase were detected in high abundance in the oil-contaminated fields. Canonical correspondence analysis indicated that the microbial functional patterns were highly correlated to the local environmental variables, such as oil contaminant concentration, nitrogen and phosphorus contents, salt and pH. Finally, a total of 59% of microbial community variation from GeoChip data can be explained by oil contamination, geographic location and soil geochemical parameters. This study provided insights into the in situ microbial functional structures in oil-contaminated fields and discerned the linkages between microbial communities and environmental variables, which is important to the application of bioremediation in oil-contaminated sites.