Research has shown that bacteria - among the simplest life forms on Earth - have a sense of smell.
Scientists from Newcastle University in the UK have demonstrated that a bacterium commonly found in soil can sniff and react to ammonia in the air.
It was previously thought that this "olfaction" was limited to more complex forms of life known as eukaryotes.
The finding, published in Biotechnology Journal, means that bacteria have four of the five senses that humans enjoy.
The discovery also has implications in the understanding and control of biofilms - the chemical coatings that bacteria can form on, for example, medical implants.
Bacteria have already demonstrated the ability to react to light, in analogy to sight, and to change the genes that they express when confronted with certain materials, in analogy to touch.
However, there is a distinction between an organism reacting to a chemical that it encounters directly (in analogy to the sense of taste) and a reaction to a chemical that is floating around in the air, says Reindert Nijland, lead author of the study.
"The difference is both in the mechanism that does the sensing, as well as in the compounds that are sensed," Dr Nijland, now at University Medical Centre Utrecht in the Netherlands, told BBC News.
"The compounds detected by olfactory organs are generally much more volatile than things you can taste like 'sweet' or 'salt', and therefore can provide information about things that can be much further away; you can smell a barbecue from a few blocks away whereas you have to physically touch and eat the steak to be able to actually taste it."
Bacteria are known to use their "senses" to detect chemicals that indicate the presence of other bacteria or competitors for food.
In some cases, they can produce a slimy material that causes them to stick together in what is known as a biofilm. Such biofilms can cause complications in cases ranging from implants to oil pipelines, but a familiar example is the plaque that forms on teeth.
Dr Nijland and Grant Burgess put a number of separate cultures of a bacterium called B. licheniformis in cylinders containing different "growth media" to cause them to multiply. Some were in a rich broth of food that allowed the bacteria to multiply quickly, releasing ammonia gas in the process, while others were in a medium that allowed the growth of biofilms - which can be initiated if the bacteria are in contact with ammonia.
They were surprised to find that some of the isolated bacteria cultures began to form biofilms spontaneously, with those physically closest to the "well-fed" bacteria showing the highest biofilm production.
The only explanation is that the bacteria sensed the presence of ammonia directly from the air above the cultures.
Dr Nijland explained that the biofilm provides both a barrier and a means of transportation for the bacteria that have "smelled" nearby ammonia.
"It's tempting to speculate that [ammonia] provides the bacteria with information of a nearby nutrient source, since ammonia generally is a waste product of bacteria growing on a rich nutrient source," he said.
"The bacteria sense this, organise themselves in a biofilm which will prepare them for both competition with other species already feeding on the nutrient source, and enables swarming - migration via the matrix they have secreted to form the biofilm."
The surprise find has implications in our understanding of the difference between prokaryotes like bacteria, which have no neatly packaged parts within their cells, and the more advanced eukaryotes that include everything from yeast to humans.
"If very simple organisms such as bacteria are capable of this that would imply that this ability evolved much earlier than expected," said Dr Nijland.
"Understanding this phenomenon... will help us to develop methods to potentially interfere with this process and potentially develop new ways of preventing biofilm-related bacterial infections."