Apple Inc. and Goldman Sachs Group Inc. rolled out a virtual credit card on Tuesday, which will help the iPhone-maker diversify from device sales and also build out the Wall Street bank's new consumer business.

With the card, Apple aims to draw in iPhone owners with 2 percent cash back on purchases with the Apple Pay service, no fees and an app to manage related finances.

For Goldman, the card will enhance the bank's focus on its Marcus consumer banking brand, which it started in 2015 to even out volatile results from businesses such as trading and investment banking.