Highly uniform GaAs/GaAsP coaxial nanowires were prepared via selective-area metal organic vapor phase epitaxy. Photoluminescence spectra from a single nanowire indicate that the obtained heterostructures can produce near-infrared (NIR) lasing under pulsed light excitation. The end facets of a single nanowire form a natural mirror surface to create an axial cavity, which realizes resonance and give stimulated emission. This study is a considerable advance toward the realization of nanowire-based NIR light sources.