When in doubt, copy whatever Apple is doing.

That’s the approach Google appears to be taking with the launch of Android Pay, a new mobile-payments system that closely mimics the Apple Pay platform launched last fall.

Scrambling to play catch-up, Google crucially has cut partnerships with a slew of big retailers including Macy’s, Best Buy, Walgreen, Whole Foods and McDonald’s.

That list of retailers looks a lot like Apple Pay’s, and cutting those partnerships is something that the search giant’s flopped Google Wallet system failed to do when it was launched in 2011.

Android Pay, which is slated for launch in the coming months, is likewise partnering with American Express, Visa, MasterCard and Discover, as well as a slew of bank card issuers, it said Thursday at its annual developers conference.

Nevertheless, industry insiders said Android Pay faces at least one key hurdle that Apple Pay doesn’t.

Google’s Near Field Communication technology will be at odds with Samsung’s upcoming “Samsung Pay” platform, which operates using the magnetic strips of traditional card readers.

That could pose a big headache for Google, given that Samsung is far and away the most popular Android-based smartphone, accounting for nearly two-thirds of all Android-based devices.

“It’s a potentially thorny issue,” says Jay Bhattacharya, CEO of all-in-one payment service Zipmark.

Like Apple Pay, Android Pay will use fingerprint ID verification.

Succeeding in mobile payments is crucial for Google, whose investors have grown increasingly impatient with the company’s inability to generate profits outside its search business.

In particular, analysts say mobile payments could help Google learn more about the effectiveness of its search ads.

Broadly, there’s reason for optimism about mobile payments, according to marketing firm Interactions, which estimates that 30 percent of shoppers already use mobile wallets. Of those who don’t, 62 percent expect to use it within the next year, according to the firm.

Elsewhere at its I/O developers conference in San Francisco, Google unveiled a slew of other new products, including: