Arlene McCarthy, a Labour MEP for the north-west, said the new rules, known as Mifid, would "curb speculation and help decrease price volatility and inflation" which had a "devastating impact on poor and food dependent countries".
"For the first time the EU will regulate commodities to tackle food speculation," she said.
McCarthy said the rules would establish "an effective system of limits on the positions taken by financial players to curb speculation and help decrease price volatility and inflation of staple foods and other commodities".
The new rules, which have to be ratified by individual nation states, come after a series of high profile stories detailing the millions banks, hedge funds and commodity traders have made from betting on the price of food.
The United Nations estimates that annual financial trading in food commodities has risen from $65bn (£41bn) to $126bn in the past five years, which has helped push the price of some basic staples to a 30-year high.
At the height of a severe drought in 2011, the head of food trading at commodity trader Glencore told investors that the drought was good for Glencore because it could exploit soaring prices.
Michel Barnier, the European commissioner responsible for financial services who led two years of negotiations ahead of the vote late on Tuesday, has described companies' profiteering from food trading as outrageous.
He said: "[The new rules] are a key step towards establishing a safer, more open and more responsible financial system and restoring investor confidence."
The rules will limit the size of positions that traders can hold in a broad range of commodities, including food staples. The limits will be set nationally, rather than at a European level, and countries have two years to implement the rules into national legislation. The Treasury had been lobbying for less strict regulation.
Marc Olivier Herman, Oxfam's EU policy advisor, said the rules were a "good start in tackling gambling on food prices which are a matter of life and death to millions in the developing world.
"The agreement introduces limits on speculating in spite of attempts by the UK and other governments to block any meaningful reform."
The World Development Movement (WDM) claims Goldman Sachs, Barclays, Deutsche Bank, JP Morgan and Morgan Stanley made £2.2bn speculating on the price of food between 2010 and 2012.
Nick Dearden, director of the WDM campaign, said: "Public outrage over food speculation has been huge and the fact that the EU has listened to that anger is a victory for public pressure. But the UK's role in watering down the regulation has been a disgrace."