Ecological divergence plays a prominent role in the process of speciation, but how divergence occurs in the face of gene flow is still less clear, and remains controversial among evolutionists. Here we investigated the nucleotide diversity, divergence and gene flow between Oryza nivara and O. rufipogon using sequences of seven chloroplast and nuclear loci. By analysing samples from 26 wild populations across the geographic ranges of the two species, we showed that both species were highly structured and O. rufipogon maintained a higher level of species-wide diversity than O. nivara. Notably, phylogenetic, amova and FST analyses were unable to detect significant nucleotide differentiation between the two species. We estimated that the two species began to diverge at c. 0.16 million years ago. Our coalescent-based simulations strongly rejected the simple isolation model of zero migration between species, but rather provided unambiguous evidence of bidirectional gene flow between species, particularly from O. rufipogon to O. nivara. Our simulations also indicated that gene flow was recurrent during the divergence process rather than arising from secondary contact after allopatric divergence. In conjunction with different morphological and life-history traits and habitat preference in the two species, this study supports the hypothesis that these Oryza species are better treated as ecotypes that diverged quite recently and are still under the process of divergence. Importantly, we demonstrate the ecological divergence between O. rufipogon and O. nivara in the presence of significant gene flow, implying that natural selection plays a primary role in driving the divergence of the two Oryza species.