Shares of companies with high levels of floating-rate debt are lagging behind the S&P 500, a sign of investor jitters about the financial impact of rising short-term interest rates.

As rates climbed, shares of 50 companies whose floating-rate bonds account for more than 5% of their total debt fell about 4% this year through March 29, according to a report by Goldman Sachs. That is worse than overall index’s 1% decline in that time.

Since...