A SWISS life-settlements firm called Rigi Capital Partners (RCP) recently considered buying the life-insurance policy of an elderly woman apparently suffering from dementia. RCP would take over payment of the policy premiums and receive the full death benefit when she passed away. Her medical records revealed that she had forgotten even her son's birthday. But Robin Willi, RCP's owner, searched Facebook to find out more about her. Her profile suggested she had a vibrant social life, not dementia. Reckoning that she was much healthier than she wanted to appear, Mr Willi did not offer to buy her policy.

Medical records can be deceptive, incomplete or expensive to analyse. Mr Willi thinks that publicly available data will be increasingly useful in helping insurers distinguish the aerobics enthusiasts from the couch potatoes. His firm is small enough to be able to search for data manually. For bigger insurers, software is now being developed by technology firms such as Allfinanz and TCP LifeSystems to sift through all the marketing data that might help them identify tomorrow's cancer patients or accident victims.

Such information can be bought from marketing firms that aggregate data about individuals from records of things like prescription-drug and other retail sales, product warranties, consumer surveys, magazine subscriptions and, in some cases, credit-card spending. At least two big American life insurers already waive medical exams for some prospective customers partly because marketing data suggest that they have healthy lifestyles, says Tim Hill of Milliman, a consultancy that advises insurers on data-mining software systems.

The software picks up clues that are unavailable in medical records. Recklessness in one part of someone's life is a pretty good signal of risk appetite in others, for example. A prospective policyholder with numerous speeding tickets is more likely than a safer driver to end up with a sports injury. The software also detects obscure correlations. People who frequent ATMs so they can make cash payments tend to live longer than those who prefer writing cheques or paying with credit cards, it turns out. People with long commutes tend to die younger. Why this should be is not clear: some speculate that ATM users tend to be more spontaneous types, who like to have cash in their pocket and whose lifestyle may be more active; others hypothesise that sedentary commutes mean less time to do something healthy in the evening.

The technology is not perfect. For some predictions it cannot beat a blood test. But manual underwriting with medical tests can cost hundreds of dollars and, according to one estimate, drags on for an average of 42 days in America and Europe. That gives potential customers ample time to talk to a competitor or walk away. Automated underwriting can cost a tenth as much and be done once a human reviews the software's recommendation.

Insurers' interest in data mining will only grow, says Kevin Pledge, the boss of Insight Decision Solutions, an underwriting-technology consultancy based near Toronto. He has investors interested in a project to develop software to comb Facebook and Twitter for promising sales leads: a woman proud of her pregnancy might want to buy life insurance, for example. Insurance firms will also analyse grocery purchases for clues about policyholders, he predicts. But that raises some sticky questions about privacy. Mr Pledge himself has begun to forgo his supermarket loyalty-card discount on junk food and pay for his burgers in cash. Promising as data mining is, much will depend on how regulators, and consumers, react.