"No one's quite nailed it yet" said Apple executive Phil Schiller of the increasing number of home speakers and voice assistants on the market.
"Just like iPod reinvented music in our pockets, HomePod will reinvent music in our homes," he added, on stage at the Apple developer conference WWDC.
Read more: Apple's just revealed a new iPad Pro
It comes with Apple Music and uses Siri, the iPhone voice assistant, to take commands.
This means it also works as a home assistant, taking on the Alexa-powered Amazon Echo and Google Assistant on the Google Home speaker.
It will go on sale in selected countries, including the UK, in December, priced at $349 (£270). That's a slightly higher price than its rivals.
Schiller was also keen to push the privacy settings of the HomePod, explaining that no sounds were heard by the device until users say Hey Siri. The information is then shared with Apple as anonymised and encrypted data.
"It is little surprise that Apple has decided to launch a smart speaker," said CCS Insight analyst Geoff Blaber.
"It can’t afford to yield valuable real-estate in the heart of people’s homes to Amazon, Google and others as access to content, information and search becomes pervasive and less dependent on the smartphone."
He added: "Apple’s HomePod speaker casts fresh focus on Siri and will draw inevitable comparisons with the AI smarts of Amazon, Baidu, Google and others. This is the product that will measure Apple's progress and whether its stance on privacy hinders its machine learning endeavours."