Johnson & Johnson reported second-quarter sales and profit that exceeded Wall Street expectations, driven by robust demand for its immunology drug Tremfya and oncology blockbuster Darzalex.

The pharmaceutical and consumer health giant also increased its full-year sales and profit forecast, signaling confidence in its pipeline despite headwinds from older products facing patent erosion.

The results highlight the company's successful transition toward a higher-margin pharmaceutical mix.

Growth from Tremfya and Darzalex more than compensated for declines in legacy product lines, reinforcing J&J's position as a resilient player in the healthcare sector.

Investors have been closely watching how the company manages the lifecycle of its key assets, and this quarter's performance suggests the current growth drivers are holding firm.

This earnings beat follows a period of heightened scrutiny on J&J's pipeline development.