DEF is used in selective catalytic reduction in order to lower NOx concentration in diesel exhaust. It does not negatively impact MPG, or engine performance. These react with the NOx in the exhaust, reducing the NOx into water and nitrogen.

Image courtesy of mppumps.com