The Nokia Lumia 1020 can produce two image files for each photo - one full resolution shot and one supersampled 5MP image. We'll be looking at both but the 5MP photos are easier to share, while the full resolution shots allow you to zoom and reframe a shot after the fact. They are great to look at as well, though you (or your image viewer) will inevitably have to downscale them unless you have an 8K TV (you don't).
With supersampling, the Lumia 1020 produces 5MP shots that have very little noise and more detail than the 8MP and 13MP photos of the other two. The camera also has very impressive dynamic range, so the lack of dedicated HDR mode isn't felt as strongly.
The other two produce good shots too, but you can see that the resolved detail is lower in some areas (like foliage) due to noise reduction. Still, LG G2 photos have more detail than the iPhone 5s shots and its color rendering is spot on. The iPhone is a bit off, while color saturation in the Lumia 1020 photos is higher than we would have liked (Nokia made a decision to up the saturation compared to the 808 PureView).
Full resolution shots look great too - obviously they have more noise and less detail per pixel, but pixel peeping on a 38MP photo is really beyond the point of smartphone photography. We upscaled the iPhone and LG G2 photos to match the resolution of the Nokia to more easily show the difference in captured detail.
The LG G2 doesn't do too bad actually, it has a noticeable lead on the iPhone 5s most noticeable in the foliage, but you can also see it in the building in the first crop and the bricks in the third crop.
The iPhone 5s has the lowest resolution camera of the three, but three generations of improvements have made it the best 8MP shooter on a phone. Photos have little noise and plenty of detail, just not as much as some of the best 13MP shooters.
The LG G2 captures 5 megapixels more than the iPhone, but the higher noise levels close the resolution gap a bit. Still, the higher resolution allows the G2 to capture some areas of complex detail better than the 5s camera.
Here are some crops to demonstrate the dynamic range and the HDR mode.
Winner: Nokia Lumia 1020. The Nokia Lumia 1020 produces amazing 5MP photos and that's that. The full resolution shots look good too, but 5MP is quite enough for virtually all displays. It still pays to shoot full res shots as they allow you to enjoy zooming, cropping and reframing on the phone later on.
Runner-up: LG G2. The LG G2 photos have accurate color rendering and the higher resolution allows it to capture more detail than the iPhone 5s.
Third place: Apple iPhone 5s.The iPhone 5s features an improved camera over the iPhone 5 and photos do look very pleasing to the eye, but having 40% fewer pixels than the G2 (and no supersampling to rely on), takes its toll.