Flare, or stray light, is a visual phenomenon generally considered undesirable in photography that leads to a reduction of the image quality. In this article, we present an objective metric for quantifying the amount of flare of the lens of a camera module. This includes hardware and software tools to measure the spread of the stray light in the image. A novel measurement setup has been developed to generate flare images in a reproducible way via a bright light source, close in apparent size and color temperature to the sun, both within and outside the field of view of the device. The proposed measurement works on RAW images to characterize and measure the optical phenomenon without being affected by any non-linear processing that the device might implement.