It could be just the thing for anyone watching their waistline – a handheld scanner that instantly counts how many calories are in whatever you’re eating, wherever you are.

Makers of the SCiO claim it can also estimate the fat, carbohydrates and protein in every portion.

The gadget uses beams of light to analyse the molecular ‘signature’ of the user’s meal, sending data to their smartphone which checks a database to identify the make-up of the food.

Gadget: Makers of the SCiO claim it can also estimate the fat, carbohydrates and protein in every portion

The technique, known as spectrometry, is used in science for analysing everything from chemicals in labs to the chemical makeup of distant stars.

Consumer Physics, an Israeli company, unveiled the gadget at the Wired 2015 technology conference in London.

To assess accurately the number of calories the user would have to identify the portion size of the piece of food that is being scanned.

The device may also prove useful to emergency services personnel for identifying pills, using the same method.

Dror Sharon, the company’s chief executive demonstrated the hand-held device successfully identifying a Viagra tablet.

The gadget uses beams of light to analyse the molecular ‘signature’ of the user’s meal, sending data to their smartphone

Commenting on the device on the company’s website, Mr Sharon said: ‘Our pill-scanning application is all about identifying the pill itself. In fact, it can distinguish between a brand-name aspirin and generic aspirin.’

Mr Sharon said his company was building a ‘database of matter’ in various areas such as food and medicines.

The machine will be launched next year but it is available for pre-order at £160. Test devices have been released to 1,000 companies, allowing them to create apps using the technology.