When I was pregnant with my first child, I was committed to breastfeeding. I wanted to do what was best for my baby, and it was hard to avoid the message that breastfeeding was a big part of this.

In hospital, after Penelope’s birth, I delicately placed my daughter’s head in the direction of my breast. She did nothing. “You have to jam it on there,” the nurse explained, repositioning me. Things didn’t get much easier at home. Penelope lost weight and I had to supplement my breast milk with formula. I pumped and pumped to encourage my milk to come in, and tried to convince her to feed.

Eventually, after three frustrating months, it worked (mostly), although I never really produced enough milk, even with pumping several times a day at work and in the middle of the night.

My experience is not unique. For some women, breastfeeding is easy, convenient and wonderful. For others, it is frustrating, painful and debilitating. These struggles are made worse by the societal emphasis on the incredible benefits of breastfeeding. Breast milk will, supposedly, make your child a smarter, thinner, healthier adult, who is protected from all kinds of terrible illness. If you cannot breastfeed – or, God forbid, you simply choose not to – the shame can be immense.

When you look at the purported benefits of breastfeeding, though, it is hard not to wonder if they are all real. Could breastfeeding matter that much in, for example, the UK or the US, where formula is a safe, clean option?

When I began to write my book, Cribsheet – a data-driven guide to parenting – one of the first tasks was to read the extensive medical literature on breastfeeding, and ask the key question: does the evidence support all the claims made about breastfeeding? I read hundreds of papers, and used my background in economics to evaluate which of them showed convincing causal effects of breastfeeding and which showed only correlations.

There is a key issue with estimating the relationship between breastfeeding and child outcomes, which is that women who breastfeed are different from those who do not. Women who breastfeed tend to be more highly educated and richer, for example. Outcomes – things such as IQ or obesity – tend to be better for children whose mothers are better educated, regardless of breastfeeding, so it is hard to separate the effect of breastfeeding from these other factors.

Let’s take, as an example, the impact of breastfeeding on IQ. Women are often told that breastfeeding will make their child smarter. We can see why this might be: on average, kids who were breastfed have higher IQ scores than those who were not. Many studies show this, including a paper published in 2006 in the British Medical Journal using a sample of more than 5,000 children.

As a first step, the authors compared IQ test scores for children aged between five and 14 who had been breastfed with those who had not. They found that the children who had been breastfed had scores about four points higher than those who had not. This is consistent with many other findings in medical and public health literature.

Emily Oster with her daughter, Penelope.

The authors also found, however, that women who breastfed were better educated and richer than those who did not. To separate out the impacts of breastfeeding from these other factors, their first step was to control for these factors, using a statistical method called regression analysis. In effect, they asked whether IQ scores for breastfed children were still higher among mothers with the same levels of education and income.

They found that they were, although the effects were much smaller – more like 1.6 points higher rather than four. But they also observed that, even among mothers with the same level of education, the IQ scores of the mothers differed. Once the authors controlled for the mother’s IQ score, the effect of breastfeeding was even smaller, at 0.5 points.

But even this may not be fully sufficient. It would be useful to compare children with the same mother, with and without breastfeeding. This study was able to do that, by looking at a sample of siblings where one sibling was breastfed and one was not. This analysis – sometimes called a “sibling fixed effects” analysis – is able to fully control for all characteristics of the mother and is a more convincing way to isolate the impacts of breastfeeding. When the authors did this, they found that the effect of breastfeeding on IQ was 0.02 points – basically, zero.

This is by no means the only study on the relationship between breastfeeding and IQ, and it is not the only study that uses this method. Looking across all the available studies, I find that the best data on the relationship between breastfeeding and IQ doesn’t support a link. A huge number of papers show a correlation between breastfeeding and IQ, but those that are able to adjust for differences across mothers – by comparing siblings or, in one case, with a randomised trial – do not show evidence for causal effects.

This example just covers IQ. While researching Cribsheet, I went through the evidence on links between breastfeeding and a wide range of outcomes. In a number of cases, I found that the best evidence does support a link between breastfeeding and outcomes for babies (and mother). Breastfeeding seems to improve digestion in the first year, lowers rashes for infants and is especially important for preterm babies. It also seems likely that it has some impact on reducing ear infections in young children and lowers the risk of breast cancer for the mother.

On the other hand, some of the claimed benefits about long-term health – such as a lowered risk of obesity – do not seem to be supported in the best data. In a number of cases, the evidence for links (for example, between breastfeeding and longer-term digestive disorders in adulthood) is so flawed that I think we cannot learn anything from it.

Where does this leave us? In a sense, none of this argues against the claim that “breast is best”. It seems it is best in terms of infant health. Where I think we run into complexity is in how we contextualise the size of the benefits, taking into account the fact that breastfeeding is difficult and may not be practical for all.

For some mothers, bottlefeeding their babies is a necessity. Photograph: Tetra Images, LLC/Alamy Stock Photo

It is one thing to say: “Breastfeeding has benefits for your child, so let me help support you in figuring it out, and hopefully it will be something you enjoy.” It is quite another to say: “This is the most important thing you can do for your child, and if it doesn’t work for you, that’s very unfortunate and, in the long run, will have serious consequences.” Of course, no one is literally saying the latter, but this is how a lot of women are hearing what is said.

The debate has spilled out of parenting blogs and the medical literature into policy. The UK has low breastfeeding rates, and this is clearly of concern to some. In April, the president of the National Childbirth Trust quit over concerns that the NCT was providing too much support for mothers who did not exclusively breastfeed. Her concerns were that this was a slippery slope: providing support for all women, regardless of how they feed their babies, risks losing the message that breast is best. Of course, the flipside of this is that, by providing a more inclusive message, more women may feel helped and supported.

Many of the benefits women hear about are speculative, or do not show up in the best data. It can feel as if policy is centred around the idea that, if women just believe this is important enough, it will magically work for them. But many women don’t need the promotion, they need support. They need help figuring out how to get breastfeeding to work, they need help managing supply, they need help with cracked and bleeding nipples. When women return to work, they need help with pumping logistics and support.

When it does work, breastfeeding can be awesome. I struggled with my daughter, but there were also many wonderful moments. And when my son came along, and I knew what I was doing, breastfeeding was fantastic. I enjoyed it, it was easy, it was convenient, and it worked for us. I believe we would be better off in a world where women get enough support to find out if breastfeeding works for them, and if they decide it doesn’t, formula-feeding is supported and not shamed.

Cribsheet: A Data-Driven Guide to More Relaxed Parenting, from Birth to Preschool by Emily Oster is out now from Souvenir Press