In the search for low-carbon energy carriers, there is renewed interest in hydrogen. However, it remains highly uncertain to what extent hydrogen may be deployed in a future energy system, and at what cost. We improve on the state-of-the-art integrated assessment model GCAM and run several scenarios in which the global energy system reaches carbon neutrality by deploying different mitigation technology portfolios, including hydrogen, direct electrification, and negative emission technologies. Across a range of scenarios we confirm that hydrogen is an important mitigation technology for 'difficult-to-electrify' sectors such as cement, fertilizer, chemical, and iron and steel production, international shipping and heavy freight truck transport. Crucially however, we find that deploying hydrogen can reduce mid-century mitigation costs by 15-23%, compared to counterpart scenarios without hydrogen availability. Our findings can guide optimal investment decisions for effective climate change mitigation.