We took photos in a dark room from about 2.5m (8.2ft) away from our subject. We shot both with the flash forced off and on. Since the Nokia Lumia 1020 produces two photos for every click - 5MP and 38MP - we should note we took the 5MP ones, which have reduced noise thanks to supersampling (those are easy to share too, no point in sharing 16MB photo with heavy noise).
With the flash off, the large BSI sensor and f/2.2 aperture of the Lumia 1020 gave it a clear advantage. The shutter speed dropped to 1/3s, though and even the OIS didn't help to prevent a good deal of the photos ending up blurry. Still, despite graininess the non-shaky shots turned out pretty well.
The iPhone 5s photos were underexposed and noisy and it too struggled with handshake. The G2 performance was more consistent and its photos are better exposed, but don't have more detail in them. This one has Night mode too, but the difference between Normal and Night mode is negligible.
Then we turned on the flash from the same position. Both the Apple iPhone 5s and Nokia Lumia 1020 flashes lit up the scene evenly, though the 1020 xenon flash is visibly stronger. The photos are very consistent and there's plenty of detail with little noise, in short the photos look great.
The iPhone 5s did fairly well too - despite the higher resolution (8MP vs. 5MP) it has less detail than the Lumia and some photos were a little shaky, but they're quite good by smartphone standards.
The LG G2 was a disappointment and we had to reshoot the photos a few times as we couldn't find the ones with flash on - turns out, they just look pretty bad. The noise goes down and there's a touch more resolved detail, but the G2 is the worst performer here, despite shooting at the highest resolution (13MP).
We guess the distance of 2.5m is outside its flash range. Also, each time the flash triggers the screen goes white and the camera gradually adjusts it which takes about a second - it's as if it doesn't expect the extra light when it turns on the flash.
Winner: Nokia Lumia 1020. The Nokia Lumia 1020 had the best shots with and without flash hands down. The OIS could have helped a bit more, but the 1020 is the clear winner here.
Runner up: Apple iPhone 5s. The iPhone 5s does very well for a 7.6mm thick smartphone that doesn't have the benefit of a huge sensor, a bulky xenon flash or optical image stabilization. Photos without flash were a bit underexposed, though.
Third place: LG G2. The LG G2 beats the iPhone 5s when the flash is off, but its single-LED flash proved too weak to be in any help in our test scene.