Most mutual funds logged losses last quarter, halting what has been a nearly uninterrupted run

Well, that was a disappointing ending.

After years of nearly uninterrupted and strong returns, most mutual funds looked set to deliver another quarter of gains, albeit modest ones, for April through June. That is, it looked that way until the eve of the quarter's end, when a sell-off in global stock markets pulled down many funds.

The losses meant less than half of all mutual funds -- 41 percent -- were able to post gains last quarter, down from 87 percent in the first quarter. Even the apparent winners ended up with weaker gains than had been anticipated just a few weeks earlier. The losses across various fund categories were mostly modest.

The question now is whether the weak finish to the quarter is just a blip or hints at a larger slowdown in the yearslong run for mutual funds. Most fund managers say they're still confident, but some doubts still linger. Stock prices have climbed more quickly than corporate earnings, leading to worries that the market may be overly valued. For bond funds, the concern is rising interest rates, which knock down the price of bonds currently inside portfolios.

Either way, many managers say investors should prepare for sharp fluctuations. Fund returns have been remarkably smooth since markets snapped higher in 2009 following the Great Recession. Now that the Federal Reserve looks likely to begin hiking interest rates later this year, and with concerns about economies around the world still smoldering, volatility may be set to rise.

Consider Vanguard's Total Stock Market Index fund, which tries to match the performance of a broad index of U.S. stocks. It was on pace for a 1.9 percent return in the second quarter, but when worries flared about Greece's debt problems on June 29, the Standard & Poor's 500 index fell to its first 2 percent loss of the year. That nearly wiped out the fund's quarterly returns, which ended up being 0.1 percent. It's the second-weakest quarterly performance for the fund in three years.

Here's a look at some of the trends that shaped the second quarter for mutual funds:

— FOREIGN STOCK FUNDS WERE STRONGEST.

Investors have been piling into foreign stock funds, largely at the expense of U.S. stock funds, for more than a year. It paid off last quarter.

Roughly 75 percent of all foreign stock funds reported gains, versus only 53 percent of their domestically focused counterparts. To be sure, economies abroad are struggling with significant problems, but stocks there are cheaper than U.S. stocks relative to their earnings.

Japanese stock funds posted an average return of 3.9 percent last quarter, for example, while European stock funds climbed 1.4 percent.

The quarter's best performers were Chinese stock funds, with an average return of 7.6 percent. But expectations were even higher just a few weeks before. The MSCI China index had been up as much as 19 percent earlier in the quarter before sinking on worries about the country's economic slowdown and concerns that a possible bubble in stocks there was bursting.

— US STOCK FUNDS SLOWED DOWN

It's easy to check how the U.S. stock funds of many investors are doing. Just check the index.

Dollars have been flooding into funds that simply track an index, whether it's one focused on large-cap stocks generally, or more narrowly on health care or another sector. More than $157 billion flowed into U.S. stock index funds over the last year, according to Morningstar, while more than $152 billion flowed out of actively managed funds.

Index funds tied to the S&P 500 alone control more than $2 trillion, for example. Too bad the index limped to a 0.3 percent return last quarter. That meant the average large-cap blend stock fund, the largest category by assets, lost 0.1 percent.

The best performers were funds that focus on just stocks delivering big earnings or revenue growth, such as Netflix. Small-cap growth stock funds returned an average of 1.8 percent, for example.

The recipe worked because growth is still difficult to find in the market: Revenue fell an estimated 2.2 percent for companies in the S&P 500 last quarter. That makes the few stocks able to exhibit big revenue gains all the more alluring.

— BOND FUNDS MOSTLY STRUGGLED

More than two thirds of taxable bond funds fell last quarter, with the biggest declines coming from those that own the longest-term bonds. Intermediate-term bond funds, which form the core of many investors' bond portfolios, slipped by an average of 1.5 percent.

They were hurt by a rise in longer-term interest rates, as the yield on the 10-year Treasury note climbed to 2.35 percent from 1.92 percent. Higher rates mean new bonds are paying more, but they also pull down prices for existing bonds.

When rates rise, long-term bonds generally incur the biggest losses because they have locked investors into the lower rates for longer, and long-term bond funds lost an average of 5.9 percent last quarter.

Virtually everyone agrees interest rates will only continue to climb, which will hinder bond funds' total returns. But many managers expect it to happen at only a gradual pace, which would enable them to avoid steep losses.