Large-cap funds were the biggest gainers; emerging market and small-cap funds lost assets.

U.S.-listed exchange-traded funds took in nearly $23 billion in July, up from $18 billion in June, according to research released Thursday.

Some $12.6 million went into U.S. equity funds, ETF.com reported.

With inflows for the January-to-July period robust, ETFs could match or exceed 2014’s record flows of $243 billion, especially given that second-half ETF flows have historically been more powerful than in the first half, the report said.

The three biggest S&P 500 funds enjoyed some of the strongest inflows in July.

SPDR S&P 500 (SPY) from State Street Global Advisors, Vanguard S&P 500 ETF (VOO) and iShares Core S&P ETF (IVV) from BlackRock attracted an aggregate $4.9 billion in assets.

“Investors really favored the safety of large-cap U.S. equities over riskier small caps and emerging markets,” Todd Rosenbluth, director of ETF and mutual fund research at S&P Capital IQ, said in the report.

In fact, funds focused on emerging markets and small caps suffered the biggest outflows in July, ETF.com data showed.

BlackRock’s iShares MSCI Emerging Market ETF (EEM) had net redemptions of $2.5 billion, a slippage of almost 7% from the previous month.

BlackRock also had a big loser in its iShares Russell 2000 ETF (IWM), with outflows of $1.6 billion. This was a turnaround from June, when the fund took in $2.1 billion.

The report indicated that investors’ appetite for U.S. fixed income had returned, as fresh net assets amounted to $6.6 billion — likely owing to expectations that the Federal Reserve will raise rates before year-end, possibly beginning in September.

BlackRock’s short-term bond fund iShares 1-3 Year Treasury Bond ETF (SHY) was the second most popular ETF in July, with net inflows of $1.9 billion in the month—second only to SPY’s $2.7 billion haul.

On the commodity front, July was not good to gold investors: gold prices fell by more than 6% to a five-year low below $1,100 an ounce.

SSgA’s SPDR Gold Trust (GLD) hemorrhaged $1.4 billion, making it the third biggest loser for the month behind EEM and IWM.

— Check out 3 Ways to Tell if a Stock Has Hit Bottom on ThinkAdvisor.