Following months of rumors and speculation, Apple has officially purchased Beats Electronics for $3 billion. The deal includes the company's headphones, speakers and audio software business as well as the recently-launched Beats Music subscription service according to a press release on the matter.

Apple CEO Tim Cook said in a statement that music is such an important part of all of our lives and holds a special place within the hearts of those at Apple. Beats co-founder Jimmy Iovine said he always knew in his heart that Beats belonged with Apple and his company was inspired by Apple's unmatched ability to marry culture and technology.

Apple will operate the Beats brand separately from its own and will continue to sell the company's headphones as well as keep the Beats streaming music service alive. iTunes and iTunes Radio will continue to be offered as well.

As per the agreement, both Iovine and fellow Beats co-founder Dr. Dre will join Apple to work under Eddy Cue who is in charge of the Cupertino-based company's Internet services division. It's unclear exactly what their roles will be with Apple, however.

Apple is paying $2.6 billion in cash for Beats as well as an additional $400 million in stock. It represents the largest acquisition yet for Apple, a company that traditionally prefers to buy out smaller startups for their talent or technology.

The deal is expected to close during the fiscal fourth quarter pending regulatory approval.