According to Juha Alakarhu, Head of Imaging Technologies at Nokia: "With oversampling, we can avoid many of the problems that traditional cameras have, and we not only overcome the problems but make things much better".

Another factor in capturing good low-light images is the quality and size of the lens. For light to actually get to the sensor in the first place, it has to go through the optics, and for low-light photography, one number is important above all others: the aperture size. This number, measured as an f-stop (where, bizarrely, smaller is bigger), determines how wide the aperture on the lens goes at maximum, and therefore how much light goes through to hit the sensor.

Again, aperture size is something phone manufacturers are pushing hard. Whereas the iPhone 4 and Samsung Galaxy S2 both featured aperture sizes of around f2.7, the iPhone 5S goes all the way down to f2.2 – and Nokia goes even bigger, with even its midrange phones like the Lumia 720 sporting a f1.9 lens. That's close to the performance of full-sized cameras, where even the best lenses, costing thousands of pounds, rarely get beyond f1.4.

In addition to the aperture size, there's something else manufacturers can play with: optical image stabilization. The reason many hardcore photographers use tripods to capture images in the dark is that by increasing the exposure time (how long the shutter's open for), you increase how much light hits the sensor. Sadly, long exposures also mean one other thing: blur, from our ever-fallible shaky human hands.

Optical image stabilization is a means of staving off blur: by essentially giving the lens a bit of suspension, minor shaking can be eliminated, and slightly longer – and brighter – exposures can be taken. Although optical image stabilisation has been a staple in high-end camera lenses for around a decade, it's a relatively new (and welcome) addition to the smartphone world, with Nokia adding it since the Lumia 920, and the HTC One following close behind.

However, optical image stabilisation, being a physical process, adds bulk to phones – one of the reasons the camera is so prominent on phones like the HTC One and Lumia 925. That's the reason why many manufacturers are now looking to a software solution to low-light photography – post-processing.

Left: 100% crop before noise reduction; right, after.

Click here to see the full-res image

Just as Photoshop can fix red-eye and a wonky horizon, software can also fix the noise: it's just a matter of processing power. With phone processors now routinely quad-core monsters like those packed into the Samsung Galaxy S4 and Lumia 1520, processing power is abundant – and image processing, historically a task out of reach of mobile devices, is now pretty simple.

Nokia has been "building its own propriety imaging algorithms", and it's now even added support for the lossless RAW image format, which is far more friendly to post-processing on computers. Hopefully, that means upcoming smartphones will hit higher ISO levels with less noise, all meaning there's a better chance of you getting a half-decent selfie in the next bar you choose to frequent.

Across the board, then, there's no indication of the low-light improvements slowing down. Although some things – like the size of the aperture – are almost as good as they can physically get, there's constant improvement across the board, all minor changes that promise major rewards in the near future.

According to Nokia, "The overall image quality is the combination of all these things coming together, and we continue to work hard and push the boundaries in all of these areas".

But with the best cameras still costing thousands of pounds, not to mention being larger than a whole flock of iPhones, the challenge is reducing these breakthroughs down to a size – and more importantly, price – where they can be crammed into our pockets.