Red Hat Inc. said its revenue rose 15% in the latest quarter, though the open-source software provider’s results were dented by negative currency effects.

Shares rose 5.4% to $83.12 in recent after-hours trading as per-share earnings, excluding certain one-time items, and revenue beat expectations and the company boosted its revenue outlook for the year.

For...