The research, published in the journal, Scientific Reports, this month, helps explain why some people manage to get enough pep from a single cup of Joe each morning, while others need to knock back several shots of espresso before they feel full of beans.
For the study, scientists took DNA samples from over 1,100 Italian volunteers who were then asked to complete detailed questionnaires about their daily coffee habits.
When the data were analyzed, scientists identified a particular variant of a gene, known as PDSS2, which they think has a notable effect on individual appetites for black gold.
Italian respondents with the PDSS2 gene variety on average drank one cup less of coffee each day, compared to coffee drinkers who didn't have the PDSS2.
Following the discovery in Italy, the results were then replicated by scientists on a similarly sized sample of volunteers in the Netherlands.
“The tendency to drink more or less coffee is written in our genes,” said the study's author, Nicola Piratsu, from Edinburgh University's Usher Institute of Population Health Sciences and Informatics.
But how does the PDSS2 gene work?
The gene is thought to influence another set of genes which control how our cells metabolize caffeine.
In people where the PDSS2 gene variety was present, rates of caffeine metabolism tend to be slow.
But in those without the gene rates of caffeine metabolism are higher, meaning their coffee-buzz wears off faster, causing them to make a beeline for the nearest café in order to get their next fix.
Following the study, scientists said more research would be needed on a larger sample group to confirm the findings and learn more about the precise workings of the 'coffee gene'.
“We believe to have added an important piece to the understanding of the genetic basis behind coffee consumption and potentially to the mechanisms regulating caffeine metabolism,” the study said.
Coffee is the third most consumed beverage worldwide after water and tea, and scientists have long been trying to determine the genetic factors which influence consumption. The first study suggesting a hereditary aspect to drinking coffee was published in Italy in 1962.