One good way to earn superior returns over the long run is to invest in companies that are at the forefront of technological (or other) changes. That description fits Block (XYZ 5.42%) and Fiverr (FVRR -0.97%) well -- the former is a leader in fintech, while the latter is helping power the fast-growing gig economy. Neither stock has performed well this year, and in Fiverr's case, it has significantly lagged broader equities since its 2019 IPO. However, both could still deliver excellent performances over the long run. 

Person sending money through an app.

Image source: Getty Images.

1. Block

Block's shares have declined this year due to disappointing financial results. The company has rebounded somewhat over the past month, but its shares are still down 20% year to date. Even so, there are several reasons to remain bullish on the stock. Let's consider three. First, Block is an innovator. It gained popularity due to its sleek point-of-sale systems, which were especially well suited for small and medium-sized businesses. That allowed Block to create a seller ecosystem and offer its business clients a range of other services. Block is still at it.

The company recently launched Square Handheld, a portable POS that could be easily mistaken for a smartphone. The device comes with a range of functions beyond payment processing, including inventory management. Innovations like these can enable Block to extract even more value from its large Square ecosystem.

Second, the company's Cash App ecosystem also appears to be quite strong. Block offers many services that allow it to compete with more traditional banks, from a debit card to stock and cryptocurrency investing, all on a sleek, modern platform. With 57 million transacting actives -- many of whom are still not signing up for many of the app's offerings -- there is plenty of room to grow there if the company can cross-sell more of its offerings.

Third, Block's shares appear reasonably valued after the recent decline. The company's forward price-to-sales is just 1.7, which is within a range to consider it undervalued. True, there are some risks involved here. Notably, Block is going all in on Bitcoin, which has contributed meaningfully to its revenue in recent years. However, given the volatility in the cryptocurrency world, it's hardly a sure bet that it will be a net benefit for the company over the long term. Block might be somewhat risky due to that aspect of the business, but for investors who can stomach the volatility and intend to hold on to its shares for a long time, Block could be a great buy at current levels.

2. Fiverr

Fiverr became a publicly traded company just before the pandemic, during which its services were in high demand. However, that tailwind has cooled down significantly over the past few years. Even so, Fiverr has made tremendous progress. Revenue is still climbing at a decent clip and, perhaps most importantly, Fiverr has turned a profit.

FVRR Revenue (Quarterly) Chart

FVRR Revenue (Quarterly) data by YCharts

Although the stock is still far from its all-time highs, it could benefit as the gig economy continues to expand. Fiverr helps connect freelancers with the businesses that want their services. For the latter, it helps them quickly onboard people for projects -- whether one-time or recurring -- without having to make them full-blown employees who are entitled to a range of benefits. In other words, it is a faster and more cost-effective way to recruit talented workers for the team. Freelancers benefit from being able to market their skills on a platform where they know people will be looking.

The gig economy is expected to continue expanding in the coming years. Fiverr, a leading platform in this niche with a recognizable brand name and a network effect, should benefit from the trend. As the company argues, the overwhelming majority of freelancing activity still happens offline. As that migrates into online channels, it will create increasing demand for its services.

Fiverr estimates a $247 billion addressable market in the U.S. Even capturing a small fraction of that -- say, 1% -- in the next decade or so would lead to consistent top-line growth for a company whose trailing-12-month revenue is just $405.14 million. Fiverr's shares could recover and deliver strong returns for patient investors who initiate positions in the stock today.