Mobile payments have become so common in China that paying with cash is practically unheard-of, even with street performers and taxi drivers.

The mobile payment market is dominated by two apps, WeChat Pay and AliPay, which have hundreds of millions of active monthly users and make Apple Pay's 127 million global user base look small in comparison.

Paying by phone became popular in China in part because credit cards never gained the popularity they see elsewhere in the world, and because the infrastructure for mobile payments was already in place.

Phone-scannable QR codes also mean that anyone can become a merchant, since you don't need hardware like a card or chip readers.

Paying with your phone isn't a novelty in China these days. Paying with cash is.

Over the last 15 years, mobile payments in China have grown into a $16 trillion market dominated by China's two biggest tech giants — Tencent and Alibaba. Mobile payments totaled $9 trillion in 2016, according to iResearch Consulting Group. Meanwhile, the US saw $112 billion in mobile payments in 2016, according to a Forrester Research estimate.

Tencent and Alibaba's competing mobile payment apps — WeChat Pay and AliPay, respectively — are used by just about everyone in China, from fancy restaurants and high-end designer boutiques down to street vendors, taxi drivers, and even panhandlers.

The depth to which the payment method has become part of daily life was driven home for me on a recent visit to the city of Xi'an, a city of 13 million in northwestern China. At the gate of the city's ancient walls, I happened upon a group of Chinese students gathered to listen to a few musicians sing on a Saturday night.

This is not an uncommon sight in New York, where in nearly every metro station, a musician is strumming a guitar with his or her guitar case dotted with dollar bills. But the musicians in Xi'an had no open guitar case.

At first I wondered how the musicians might receive tips. But every couple of songs, one of their friends held up two cards printed with QR codes — one for Alipay and the other for WeChat Pay. Dozens of the attendees lifted up their phones and, in seconds, had scanned the QR code and sent a few yuan to the performers.

It was genius.

No more digging around for loose change and finding you only have a $20 bill. No more trying to push your way to the front of the crowd so that you can deposit a few coins in the guitar case. Only a couple of clicks.

In China's major cities, mobile payments are the preferred way to pay for just about everything

Harrison Jacobs/Business Insider

It would be easy to write my anecdote as some particularly tech-savvy millennials, except for the fact that such uses of mobile payments are common, and not just with young people.

Tencent's WeChat Pay has a whopping 900 million monthly active users, while Alipay, from Alibaba affiliate Ant Financial, has over 500 million monthly active users. Almost all of those users are Chinese nationals.

For comparison, Apple Pay has 127 million users globally — and it comes pre-installed on every iPhone.

Walking through the colorful Muslim Quarter street market in Xi'an the following day, I noticed that all of the food vendors had set out AliPay and WeChat Pay QR codes for tourists to pay for their food. I was the only one paying in cash.

I saw the same at street-side fruit stands in Shenzhen and Beijing weeks later. One coffee shop in Beijing didn't even have a register, only a QR-code scanner. I had to leave and go to a different cafè because all they accepted was mobile payment.

Phone-scannable QR codes means that anyone can become a merchant. No one needs hardware like a card or chip readers. All you need is an account and your personal QR code. Print it out on a sheet of paper and anyone passing by can send you money. Or simply scan the QR code of the person trying to pay you.

Ninety-two percent of people in China's top cities said that they use WeChat Pay or AliPay as their primary payment method, according to a 2017 study by Penguin Intelligence. And the amount spent per month through those services keeps going up.

Chinese spending using cash, however, is down around 10% over the last two years, according to The Wall Street Journal.

Young Chinese people I spoke to said they rarely carried a wallet or cash at all. There was no point. Smartphones were the easiest way to pay for things, so why bother?

Mobile payments have become wildly popular in China for two reasons

Harrison Jacobs/Business Insider

It is clear that mobile payments have taken off in China in a way that they have yet to in the US or Europe. While it is tempting to suggest that this has occurred because China is so far ahead technologically, the reality is that it comes down to existing infrastructure.

Credit cards were never popular in China, due in large part to poor options, cultural attitudes about debt, and, until recently, the lack of disposable income. China's state-owned banks, meanwhile, are notoriously difficult to deal with.

When AliPay launched in 2004 as an escrow-service between buyers and sellers on Taobao, Alibaba's massively popular consumer-to-consumer e-commerce platform, it provided a much needed layer of security and trust. By the time it evolved in a mobile payment service in recent years, it already had a large user base. And compared to signing up for a credit card or using the state-owned banks, AliPay was infinitely more user-friendly.

Meanwhile, WeChat Pay is a function within WeChat, Tencent's messaging app that is used by more than 1 billion people. It has been China's most popular app for some time.

The payment function was launched in 2014 during Lunar New Year, when it is common in China to give friends and family red envelopes of cash. Tencent drove adoption by allowing WeChat users to gift digital red envelopes of money to groups of friends. Users who opened the packets first — and, in the process, signed up for WeChat Pay — got bigger sums.

WeChat Pay saw 16 million red envelopes get sent in the first 24 hours of launch, according to The Wall Street Journal. Pretty quickly, the app became the primary way for friends to send money to each other or split bills, similar to Venmo in the US.

Alibaba and Tencent are sitting on a treasure trove of consumer data

Facebook founder and CEO Mark Zuckerberg and Founder and Executive Chairman of Alibaba Group Jack Ma laugh as they meet at the China Development Forum in Beijing, China, March 19, 2016. REUTERS/Shu Zhang

The benefits for Alibaba and Tencent go far beyond the transaction fees collected. The ubiquity with which Chinese people use mobile payments means the companies are sitting on a treasure trove of consumer data.

WeChat and Taobao, Alibaba's primary app, both serve a variety of functions from messaging, social networking, and e-commerce to taxi-hailing, bike-sharing and travel booking. The consumer data from payments is used to build detailed profiles of each user, which can then be monetized for marketing purposes directly within their apps in ways that even Facebook and Google would salivate over.

For example, that baby formula that you bought from the convenience store is telling Taobao to start sending you ads and promotions for other infant products to buy directly in the Taobao app.

Further, both Tencent and Alibaba have credit scoring businesses — Tencent Credit and Zhima Credit, respectively — that heavily factor payment histories into their scores. Both companies are beginning to introduce other financial products, such as loans and money market funds, as well.

In terms of market share, Alipay has 54% compared to 40% for WeChat Pay, according to iResearch Consulting Group. But the battle for who will dominate the mobile payments industry is only just starting to heat up.