Facebook (NASDAQ:FB) and Alphabet (NASDAQ:GOOG)(NASDAQ:GOOGL) subsidiary Google are the market leaders in the digital ad category. Their hold on the market is so strong that it's drawn the scrutiny of governments around the world. With no real challenge to that grip, some call the pair a duopoly.

The trend of increasing ad dollars shifting to digital is continuing. The digital advertising market is forecast to grow at an 8.4% compounded annual rate through 2023, according to PwC. Let's look at which one of the two is a better investment.

A rising bar chart on a digital screen.

Image source: Getty Images.

The case for Alphabet

Google is dominating the search market. Its search engine had an over 90% global market share in mobile search results last year. It's the first place people go when people want to search for something online. This entrenchment in the search advertising space gives Google a strong moat around this stream of revenue.

Alphabet's other revenue, which includes Google Cloud, is experiencing rapid growth. The fact that Alphabet is participating successfully in the cloud market, which is forecast to grow at a compounded annual rate of 22%, gives it an advantage over Facebook. Furthermore, the revenue stream provides diversification from advertising revenue that Facebook does not have.

Further, Alphabet faces a smaller legal burden compared to Facebook, which had to pay a record-breaking fine of $5 billion in July of 2019 as part of a settlement with the Federal Trade Commission. As part of the agreement, Facebook must update and improve its privacy protections, which will increase costs. The expenses stemming from this settlement are already impacting its earnings. The increase in the costs and uncertainty surrounding how long and how much they will end up totaling is a significant reason to choose Alphabet over Facebook.

The case for Facebook

Facebook, however, is growing revenue faster than Alphabet, which is one factor that makes Facebook a better investment. Between 2013 and 2018, Alphabet's revenue grew at a compounded annual rate of 20%, while Facebook's grew by an incredible 48%. Increasing revenue more than twice as fast as its counterpart is a compelling reason to invest in Facebook.

The opportunity to monetize WhatsApp and Messenger is another advantage Facebook has over Alphabet. With 1.6 billion and 1.3 billion monthly active users, respectively, these two apps have enormous revenue-generating potential if and when Facebook decides to monetize the apps.

Another persuasive case for Facebook over Google is the amount of detailed information Facebook has on the social behavior of its users. Facebook not only knows your birthday, but it also knows what you did the last few years to celebrate your birthday. Imagine the value that adds to an advertiser if they know you like to go out for sushi with friends on your birthday, or that you usually like to travel the weekend of your birthday. This type of detailed information makes Facebook more attractive to advertisers looking to target specific groups.

The better investment

Both companies exhibit incredible growth potential and have a strong position in the digital advertising arena. The distinguishing factor that lifts Alphabet above Facebook is its lower level of legal risk. The requirements associated with Facebook's settlement with the FTC have increased its expenses indefinitely, and that is a significant negative against the social network.

Choosing between these two incredible tech stocks is difficult. However, Alphabet provides excellent growth potential with a lower level of risk compared with Facebook. Therefore, if you could only invest in one of these two stocks, it should be Alphabet.