Children who eat a Mediterranean diet have a lower risk of developing asthma, but eating three or more burgers a week is linked to a higher risk, research suggests.
Researchers looked at 50,000 children from 20 countries.
Writing in the journal Thorax, they said eating fruit, vegetables and fish appeared to protect against asthma.
But they said eating burgers could be linked to other unhealthy habits, which may be the real trigger factor.
The study looked at the habits of children in both wealthy and poorer countries between 1995 and 2005. Parents were asked about their children's diets, and whether they had ever been diagnosed with asthma or had suffered wheezing.
The effects of their diet seemed to vary depending on where they lived.
Fruit and vegetables appeared to be more protective in less affluent parts of the world, while eating lots of fish was more helpful in richer countries.
Eating at least three burgers a week was linked to a greater risk of asthma and wheezing, but only in wealthier countries.
Dr Gabriele Nagel, one of the authors, said this may be because asthma is a collection of symptoms rather than a single condition, and different things may trigger it in different parts of the world.
"This gives us more understanding of how asthma affects different people, and its effects in developing as well as developed countries," she said.
The paper suggested that a diet rich in fruit and vegetables may be helpful because of the protective effects of antioxidants and vitamin C.
High levels of unhealthy fats in burgers could increase the risk of asthma. However, the authors said children who ate several burgers a week were likely to have other unhealthy lifestyle habits as well.
The study did not adjust for levels of obesity.
Asthma UK said the paper helped add to the understanding of how asthma and diet are connected.
But it urged caution because children's weight can have a significant influence on asthma symptoms.
Dr Elaine Vickers, research relations manager at Asthma UK, said: "Previous studies have shown that a Mediterranean-style diet rich in fruit and vegetables can help to reduce a child's risk of developing asthma symptoms.
"Our advice to parents is therefore to ensure that children eat a healthy, balanced diet and also get plenty of exercise."
Dr Keith Prowse from the British Lung Foundation said further investigation was needed for more conclusive evidence about the effects of diet and lifestyle.
"We would like to reinforce the need for children to have a balanced diet and healthy lifestyle," he said.