Google is paying Apple billions of dollars to remain the default search engine on iPhones and iPads, Bernstein said in a note to investors on Monday.

The firm believes that Google will pay Apple about $3 billion this year, up from $1 billion just three years ago, and that Google's licensing fees make up a large bulk of Apple's services business.

Apple has been touting its services business as a quickly growing segment of the company, noting that it expects that branch alone will soon be as large as a Fortune 500 company.

"Court documents indicate that Google paid Apple $1B in 2014, and we estimate that total Google payments to Apple in FY 17 may approach $3B," Bernstein analyst A.M. Sacconaghi Jr. said. "Given that Google payments are nearly all profit for Apple, Google alone may account for 5% of Apple's total operating profits this year, and may account for 25% of total company OP growth over the last two years."

Bernstein sees pros and cons in the payments.

Sacconaghi said that Google might decide to back away from paying Apple any licensing fees if it feels confident enough that its search engine is so popular Apple won't include any other option by default.

On the other hand, Sacconaghi said that Apple's iOS devices contribute about 50 percent to Google's mobile search revenue, which means Google might be too afraid to walk away from its licensing deal with Apple. In this case, it's a win-win for Apple and Google.

Bernstein has an outperform rating on Apple with a price target of $175.