United Technologies Corp. is near a deal to combine with military contractor Raytheon Co., according to people familiar with the matter, the latest move by the sprawling conglomerate to transform into a company focused on aerospace and defense.

The companies, which together have a market value of roughly $166 billion, could announce a deal in the coming days assuming talks don’t fall apart at the last minute, the person said.

Exact...