Cereal giant General Mills has agreed to buy natural pet food maker Blue Buffalo for $8 billion, entering a growing pet food market, according to officials with the two companies.

The purchase gives General Mills leverage in the rapidly growing $30 billion pet food industry.

Blue Buffalo, founded in 2002, sells more than $1 billion worth of dog and cat food and treat products yearly in the expanding wholesome natural pet food category.

"In pet food, as in human food, consumers are seeking more natural and premium products," Jeff Harmenin, General Mills CEO, said in a release.

General Mills is the third largest natural and organic food producer, with brands including Annies, Lärabar, Liberté, Cascadian Farm and Muir Glen.

General Mills will pay $40 a share for Blue Buffalo using a combination of debt, cash on hand and $1 billion in equity to finance the deal.

"General Mills will be a tremendous home for our BLUE brand as our talented team of over 1,700 'Buffs' joins this new extended family," Billy Bishop, Blue Buffalo CEO, who will maintain his position, said in a release.