Ramil Sheydaev fired over when clear through in the first half before Afran Ismayilov wasted two opportunities.
Northern Ireland withstood late pressure before Dallas won it to cement second place in Group C.
Azerbaijan looked the more likely to score a late goal but they were punished as Dallas fired home from a Jonny Evans pass.
The other four teams in the group are in action later on Saturday but Northern Ireland will be at least two points clear in second and on course for the play-off spot.
More about: #football #Azerbaijan-NortherIreland