Investing is cheaper than ever. Trading is free, some index funds may also be free, and a diversified portfolio can be built by machines at a fraction of the cost of live professionals advising in an elegant leather binder.

Within a few days in the last month, the price war among brokerage firms has driven the costs of many trades at Charles Schwab, TD Ameritrade, E-Trade and Fidelity to nothing. Then, this week, Schwab said it would buy Ameritrade for $ 26 billion – a deal that demonstrated the importance of market share in an era of cheap investments.

But investing cheaply isn't always as cheap as it seems. Many companies do other things that can cost you money by paying certain fees – and it's up to you, dear investor, to find out what they are.

The policies of each company vary, but here's some helpful information: how your broker uses your cash holdings; the cost of other services offereds; and how it can benefit from your free trades if you get someone to pay for it instead.

Over the past decade, online brokers and asset management companies have started making more money from customer cash – for example, money not yet invested – by flowing it to lower-yielding deposit accounts rather than higher-yielding money market funds, Michael Wong said, Director Financial Services Equity Research at Morningstar.

Schwab, for example, will pay you a meager 0.06 to 0.45 percent of your wealth, while investing it at around 2.65 percent and pocketing the difference, he said. Cash holdings could earn almost 2 percent elsewhere.

And that paid off for the company: Last year, net interest income accounted for almost 60 percent of Schwab's total sales. TD Ameritrade and E-Trade similarly relied on interest income that accounted for more than half of each company's sales last year.

Fidelity, which has a huge 401 (k) business, is not so dependent on interest rates – and earlier this year it was said that unused cash from all retail customers would flow into the money market with higher yields accounts. Vanguard does the same.

So yes, free trading is a nice little benefit – but you will most likely pay for it in the form of lower returns on the cash your broker holds.

And free trade may not even be worth that much to you. Only a few enlightened investors are chasing hot stocks. They buy and hold a diversified mix of index funds to pay for major life events like college and retirement. (Index funds are basic mutual funds that cover large parts of the stock market.)

The major brokerage firms know this, and many of them have followed the example of small, emerging companies like Betterment, known as roboadvisers, to provide mass-produced digital portfolios that are largely autopilot-operated and cost very little.

Schwab launched its own digital securities service in 2015 and tried to strengthen its competitors by providing a free service. But there was a catch.

Many roboadvisers typically charge a total fee – around 00.30 to 0.50 percent a client's assets annually – along with the (usually very low) underlying investment costs. Schwab omitted this total fee and only billed the costs of the underlying funds.

According to a Schwab spokesman, however, investors must hold between 6 and 29 percent of their portfolio in cash, which currently corresponds to 0.45 percent. Schwab makes more money the bigger the allocation.

In 2017, Schwab added a premium service for people with a minimum of $ 25,000 in assets, which included the help of a human-certified financial planner: it now costs $ 30 a month plus a one-time initial fee of $ 300 plus investment costs. And It also requires the high cash component.

Even with a commission-free trading structure, said Greg McBride, financial analyst at Bankrate.com, "there are other earnings levers behind the scenes that brokers can pull."