Punters beat financial markets by an hour when it came to correctly predicting Brexit on referendum night, creating a golden opportunity to cash in, a study found.

Research by the University of Cambridge found gamblers sensed the Leave result coming earlier than currency experts, after the polls closed for the June 2016 Brexit vote.

Economists studied the behaviours of the Betfair betting market and the sterling-US dollar on the night of the vote, and said the financial markets lagged behind as the results were announced.

This created an hour-long “close to risk-free” arbitrage window in which the price difference between betting and financial markets yielded up to a 7% return.

Researchers said the findings support the idea that gambling might provide better forecasts of election outcomes than either experts or polls.

“It looks like the gamblers had a better sense that Leave could win, or that it could at least go either way,” the study’s lead author Dr Tom Auld said on Friday.

Dr Auld said both betting and financial markets were in fact slow to react, given the information flooding in from vote counts.

He said this showed there was a “behavioural bias” at work as both markets had believed Remain would win before the votes were counted.

“Initially, both traders and gamblers could not believe the UK was voting to leave the EU,” Dr Auld said.

“But this disbelief lingered far longer in the City.”

The Cambridge economists also created their own forecasting model for predicting Brexit, drawing on data that was publicly available prior to the vote and adjusted as results came.

Many market theories discount publicly available information because it is deemed not to provide an edge, the study said.

But the economists said their model would have predicted the final result by 1.30am that night, while the betting market moved to a Leave result at about 3am and currency markets at about 4am.

“We show that the financial markets were very inefficient, and should have predicted Brexit possibly over two hours before they actually did,” Dr Auld said.

If there was a second referendum, the vote should be better understood by markets and “primed to profit” from any inefficiencies, Dr Auld said.

The study was published in the latest International Journal of Forecasting.