Deep-dive on the Next Gen Platform. Join the Webinar!

Skip Navigation
Show nav
Dev Center
  • Get Started
  • Documentation
  • Changelog
  • Search
  • Get Started
    • Node.js
    • Ruby on Rails
    • Ruby
    • Python
    • Java
    • PHP
    • Go
    • Scala
    • Clojure
    • .NET
  • Documentation
  • Changelog
  • More
    Additional Resources
    • Home
    • Elements
    • Products
    • Pricing
    • Careers
    • Help
    • Status
    • Events
    • Podcasts
    • Compliance Center
    Heroku Blog

    Heroku Blog

    Find out what's new with Heroku on our blog.

    Visit Blog
  • Log inorSign up
Hide categories

Categories

  • Heroku Architecture
    • Compute (Dynos)
      • Dyno Management
      • Dyno Concepts
      • Dyno Behavior
      • Dyno Reference
      • Dyno Troubleshooting
    • Stacks (operating system images)
    • Networking & DNS
    • Platform Policies
    • Platform Principles
  • Developer Tools
    • Command Line
    • Heroku VS Code Extension
  • Deployment
    • Deploying with Git
    • Deploying with Docker
    • Deployment Integrations
  • Continuous Delivery & Integration (Heroku Flow)
    • Continuous Integration
  • Language Support
    • Node.js
      • Working with Node.js
      • Troubleshooting Node.js Apps
      • Node.js Behavior in Heroku
    • Ruby
      • Rails Support
      • Working with Bundler
      • Working with Ruby
      • Ruby Behavior in Heroku
      • Troubleshooting Ruby Apps
    • Python
      • Working with Python
      • Background Jobs in Python
      • Python Behavior in Heroku
      • Working with Django
    • Java
      • Java Behavior in Heroku
      • Working with Java
      • Working with Maven
      • Working with Spring Boot
      • Troubleshooting Java Apps
    • PHP
      • PHP Behavior in Heroku
      • Working with PHP
    • Go
      • Go Dependency Management
    • Scala
    • Clojure
    • .NET
      • Working with .NET
  • Databases & Data Management
    • Heroku Postgres
      • Postgres Basics
      • Postgres Getting Started
      • Postgres Performance
      • Postgres Data Transfer & Preservation
      • Postgres Availability
      • Postgres Special Topics
      • Migrating to Heroku Postgres
    • Heroku Key-Value Store
    • Apache Kafka on Heroku
    • Other Data Stores
  • AI
    • Working with AI
  • Monitoring & Metrics
    • Logging
  • App Performance
  • Add-ons
    • All Add-ons
  • Collaboration
  • Security
    • App Security
    • Identities & Authentication
      • Single Sign-on (SSO)
    • Private Spaces
      • Infrastructure Networking
    • Compliance
  • Heroku Enterprise
    • Enterprise Accounts
    • Enterprise Teams
    • Heroku Connect (Salesforce sync)
      • Heroku Connect Administration
      • Heroku Connect Reference
      • Heroku Connect Troubleshooting
  • Patterns & Best Practices
  • Extending Heroku
    • Platform API
    • App Webhooks
    • Heroku Labs
    • Building Add-ons
      • Add-on Development Tasks
      • Add-on APIs
      • Add-on Guidelines & Requirements
    • Building CLI Plugins
    • Developing Buildpacks
    • Dev Center
  • Accounts & Billing
  • Troubleshooting & Support
  • Integrating with Salesforce
  • Extending Heroku
  • Heroku Labs
  • Heroku Labs: Disabling HTTP/2 for Router 2.0

Heroku Labs: Disabling HTTP/2 for Router 2.0

Last updated February 12, 2025

Table of Contents

  • Overview
  • Disable HTTP/2 for Apps on Router 2.0
  • Enable HTTP/2 for Apps on Router 2.0

For Common Runtime apps on Router 2.0, HTTP/2 is enabled by default. To opt-out of HTTP/2 enable the Heroku Labs http-disable-http2 feature.

Features added through Heroku Labs are experimental and subject to change.

Overview

By enabling the Heroku Labs feature, requests to your app use the HTTP/1.1 protocol or an older HTTP protocol if supported.

Disable HTTP/2 for Apps on Router 2.0

To opt out of using HTTP/2 as the default protocol, enable the Heroku Labs feature:

$ heroku labs:enable http-disable-http2 -a <app name>

You can verify your app is receiving HTTP/1.1 requests by referencing the protocol value in your Heroku Router Logs, like this example:

2024-10-25T16:01:10.881983+00:00 heroku[router]: at=info method=GET path="/" host=my-app.example.com  request_id=370b21e2-7dec-1758-6a80-e21f155dd635 fwd="138.68.186.89" dyno=web.1 connect=0ms service=0ms status=200 bytes=0 protocol=http1.1 tls=true tls_version=tls1.3

Enable HTTP/2 for Apps on Router 2.0

To opt back in to HTTP/2, disable the Heroku Labs feature:

$ heroku labs:disable http-disable-http2 -a <app name>

For more information on using HTTP/2 on Router 2.0, see the HTTP/2 considerations.

You can verify your app is receiving HTTP/2 requests by referencing the protocol value in your Heroku Router Logs, like this example:

2024-10-25T16:01:10.881983+00:00 heroku[router]: at=info method=GET path="/" host=my-app.example.com  request_id=370b21e2-7dec-1758-6a80-e21f155dd635 fwd="138.68.186.89" dyno=web.1 connect=0ms service=0ms status=200 bytes=0 protocol=http2.0 tls=true tls_version=tls1.3

Keep reading

  • Heroku Labs

Feedback

Log in to submit feedback.

Heroku Labs: log-runtime-metrics Heroku Labs: Disabling Keepalives to Dyno for Router 2.0

Information & Support

  • Getting Started
  • Documentation
  • Changelog
  • Compliance Center
  • Training & Education
  • Blog
  • Support Channels
  • Status

Language Reference

  • Node.js
  • Ruby
  • Java
  • PHP
  • Python
  • Go
  • Scala
  • Clojure
  • .NET

Other Resources

  • Careers
  • Elements
  • Products
  • Pricing
  • RSS
    • Dev Center Articles
    • Dev Center Changelog
    • Heroku Blog
    • Heroku News Blog
    • Heroku Engineering Blog
  • Twitter
    • Dev Center Articles
    • Dev Center Changelog
    • Heroku
    • Heroku Status
  • Github
  • LinkedIn
  • © 2025 Salesforce, Inc. All rights reserved. Various trademarks held by their respective owners. Salesforce Tower, 415 Mission Street, 3rd Floor, San Francisco, CA 94105, United States
  • heroku.com
  • Legal
  • Terms of Service
  • Privacy Information
  • Responsible Disclosure
  • Trust
  • Contact
  • Cookie Preferences
  • Your Privacy Choices