Measurements of temperature and NO concentration in laminar, partially premixed methane-air flames stabilized on a ceramic burner in coflow are reported. The NO concentration and temperature were determined by laser- induced fluorescence (LIF) and coherent anti-Stokes Raman scattering: (CARS), respectively. Upstream heat loss to the burner was varied by changing the exit velocity of the fuel-air mixture at a constant equivalence ratio of 1.3; this alters the structure of the flame from an axisymmetric Bunsen-type to a strongly stabilized flat flame. To facilitate analysis of the results, a method is derived for separating the effects of dilution from those of chemical reaction based on the relation between the measured temperature and the local mixture fraction, including the effects of upstream heat loss. Using this method, the amount of NO formed during burnout of the hot, fuel- rich combustion products can be ascertained. In the Bunsen-type flame, it is seen that ~40 ppm of NO are produced in this burnout region, at temperatures between ~2100 K and ~1900 K, probably via the Zeldovich mechanism. Reducing the exit velocity to 12 cm/s reduces the flame temperature substantially, and effectively eliminates this contribution. At velocities of 12 and 8 cm/s, ~10 ppm of NO are formed in the burnout region, even though the gas temperatures are too low for 'Zeldovich' NO to be significant. Although the mechanism responsible for these observations is as yet unclear, the results are consistent with the idea that the low temperatures in the fuel-rich gases caused by upstream heat loss retard the conversion of HCN (formed via the Fenimore mechanism) to NO, with this 'residual' HCN then being converted to NO during burnout.