A rising tide lifts all boats -- but a rising interest rate is more selective.

When bond rates are low, investors tend to put money into so-called "safe-haven" stocks that pay regular dividends, such as utilities and defense contractors. But as rates increase and bonds become more attractive, those stocks can suffer.

Historically low interest rates have sent haven stocks to record highs recently, with 56 utilities posting 52-week highs so far this month. But with two more rate hikes expected for this year, the safe harbor may be due for low tide.

Jonathan Golub, the chief equity strategist at RBC Capital Markets, said investors might want to consider lowering their exposure to interest-sensitive stocks.

"While people assume that they are safe havens, they're actually quite risky on a relative basis if interest rates go up," he said.

Golub said that a broad array of dividend-paying stocks stands to lose from a rising rate. Consumer staples, business services, defense contractors, utilities, large software companies and other low-volatility companies that tend to sign onto long-term contracts are all sensitive to interest rates, he said.

Rising interest rates don't necessarily mean these stocks will actually fall. Often, the Federal Reserve's decision to increase government rates suggests a strong economy. As rates rise, interest-sensitive stocks may underperform a bull market even as they make gains.

Michael Weinstein, an analyst at CreditSuisse, said that utilities stocks might be slightly overvalued. CreditSuisse released a report Friday, June 16 suggesting that the sector may have a 4% downside compared to the rest of the market.

"4% relative downside is, you could easily call that fairly valued," he said. "[Utilities] are a little bit overbought, but not significantly so."

The analyst noted that the stocks are trading at a premium relative to the rest of the market based on their price-to-earnings ratio - an oddity for stocks that tend to trade at a discount because they offer dividends.

"The idea that utilities are a premium stock is a new concept," he said. "People are hungry for dividends; they're hungry for yields. They still consider this market risky."

Weinstein noted that the market for dividend-paying stocks has been skewed since the financial crisis, when interest rates scraped near zero, putting bond-yields at record lows. According to CreditSuisse's report, the spread between the 10-year bond yield and utility dividend yields, which has grown to over 1% from a historic rate of near-zero, acts as a sort of "shock absorber," reducing the influence of interest rates on utility stock prices.

The treasury yield has been sitting below 2.5%, down from a historical average of about 4.3%.

Travis Miller, an analyst at MorningStar Research Services, said the spread between the treasury yield and the utilities dividend yield provides some cushion to utilities stocks as rates rise. Because of the unique environment, an increase in interest rates may not affect utilities stocks in the short term, he said, particularly if treasury yields remain below their historic average.

But if interest rates rise beyond that, he noted, utilities stocks could lag behind what would be a raging bull market.

"History shows almost unequivocally that utilities will underperform other sectors and the market in general when interest rates are rising," he said.