Apple Inc.’s HomePod, the company’s first foray into speakers in a decade, costs $216 to build and generates thinner profit margins than other products like the Apple Watch and iPhone, according to analysis by TechInsights.

Given the HomePod’s $349 price, that $216 cost suggests Apple is generating margins of about 38 percent, according to the product analysis firm. That compares with margins of 66 percent and 56 percent for the Google Home and Amazon Echo, products that compete in the smart-speaker market, but offer lower audio quality, according to the ...