With the stock market setting new highs, CNBC's Jim Cramer on Wednesday advised investors to take a look at their gains and start trimming positions in the winners.
Making a trade at the market's peak is a guessing game, and market players will risk losing money if they wait too late.
"It is time to ring the register on part of your position so that you're playing with, maybe, the house's money. That's the holy grail," the "Mad Money" host said. "Maybe take out what you put in, let the rest run."
Cramer, who traded his usual tie and shirt with rolled-up sleeves for a blue cashmere sweater to pay homage to his late mother, told a story about how she had a lucky hand at the slot machines and imparted advice to him to quit while you're ahead.
Louise Cramer, his mother, would collect her winnings before the luck ran out and go buy herself something nice like a cashmere sweater, he said. One of Jim Cramer's oft-repeated investing tips is that "bulls make money, bears make money, but pigs get slaughtered."
While putting money in a slot machine is not akin to putting it in the stock market, the advice holds true for investors, according to Cramer.
"She had common sense, and common sense says, even if you think you have the hottest hand in the world, when you're up big, you've gotta take some profits while you still have them," he said, adding "it's the responsible thing to do."
Cramer made the comments after another record-setting day on the stock market. The S&P 500 and Nasdaq Composite both rallied more than 1% to new highs, with the benchmark closing at 3,478.73 and the tech-heavy index finishing at 11,665.06. The lagging Dow industrials average, which will receive a makeover on Monday, closed up 83 points at 28,331.92, about 4% off its own all-time high from February.
"That lesson has stuck with me for nearly 40 years: Sometimes you've got to quit a little while you're ahead," Cramer said. "Right now, we've got the smoking-hottest stock market I have ever seen, and it rewards companies for success so generously that it's [nothing] like any other market I've ever seen."
Salesforce, which reported a record quarter Tuesday and was picked to join the 30-stock Dow on Monday, led the market with a 26% surge to $272.32. In the wake of posting 29% revenue growth and a $2.63 billion profit, the company said Wednesday afternoon that it would cut 1,000 jobs, or about 2% of its headcount, to focus on more growth in unspecified areas.
Since the March bottom, the S&P index is up more than 58% as of the close.
Disclosure: Cramer's charitable trust owns shares of Facebook and Salesforce.com.