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
      • Node.js Behavior in Heroku
      • Working with Node.js
      • Troubleshooting Node.js Apps
    • 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
    • Heroku Inference
      • Inference API
      • Quick Start Guides
      • AI Models
      • Inference Essentials
    • Vector Database
    • Model Context Protocol
  • 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
  • Security
  • Identities & Authentication
  • Single Sign-on (SSO)
  • Using Single Sign-on (SSO) Services with Heroku, for End Users

Using Single Sign-on (SSO) Services with Heroku, for End Users

English — 日本語に切り替える

Last updated March 20, 2024

Table of Contents

  • Your Heroku Authentication Experience Under SSO
  • Upgrading Your Existing Heroku Account Authentication to SSO
  • Obtaining a New Heroku Account under SSO
  • Authenticating to the Heroku CLI under SSO
  • FAQ: My Heroku account under SSO

Your Heroku Authentication Experience Under SSO

After your administrator enables single sign on (SSO) for Heroku, you can log into Heroku on your company’s identity provider. This process is similar to how you log into other cloud services like Slack and Dropbox. Your company uses the identity provider (IdP) to centralize authentication to any number of cloud or on-premise services, accessing each, usually with a single click.

As a user, you only need to enter your username and password one time at the IdP to gain access to all services under the IdP’s control.

Only your identity administrator can add Heroku to the list of service providers available to you under single sign-on. Often these service providers are presented to you in tiles on your main login page.

Email communications about single sign-on always come from your identity administrator, not Heroku. If you have questions about single sign-on or any particular communication you might receive, contact your company’s identity administrator.

Upgrading Your Existing Heroku Account Authentication to SSO

Users with a Heroku account under their work email get invited to upgrade their authentication mechanism to SSO at a URL supplied by the company’s identity admin. The upgrade process for the account changes the Heroku login to use the company’s IdP. This process gives the company authentication control over the account.

After users upgrade to SSO, they can no longer log in with personal credentials. They must use SSO. Before upgrading to SSO, we recommend that users transfer any personal apps to a different, personal, Heroku account. Users who decline or postpone the upgrade process can re-initiate and join SSO at anytime by navigating to the SSO links.

Users who cancel the upgrade process appear to organization administrators as “not under SSO.”

There’s always a “personal” area in the upgraded account, but your company can block access to that Heroku account at any time, so “personal” refers to personal in an employee context.

If your account has any long-lived tokens, they get invalidated after upgrading your account to use SSO.

Obtaining a New Heroku Account under SSO

When you log into Heroku for the first time via your company identity provider (IdP), we create a Heroku account for that email if one doesn’t already exist. Heroku trusts the organization’s IdP and creates accounts if necessary for authenticated users.

You receive a welcome email from Heroku and must click the acknowledgment link to activate your account.

Authenticating to the Heroku CLI under SSO

Use the heroku login command to log in to the Heroku CLI under SSO:

$ heroku login
heroku: Press any key to open up the browser to login or q to exit
 ›   Warning: If browser does not open, visit
 ›   https://cli-auth.heroku.com/auth/browser/***

This command opens your web browser to the Heroku login page, where you can select the SSO login option:

Running the heroku login command launches a web browser and opens the Heroku account login page, where you can select SSO login.

After you click the Log in button, the Heroku CLI automatically logs you in:

$ heroku login
heroku: Press any key to open up the browser to login or q to exit
 ›   Warning: If browser does not open, visit
 ›   https://cli-auth.heroku.com/auth/browser/***
heroku: Waiting for login...
Logging in... done
Logged in as me@example.com

You can use the legacy SSO login by setting the environment variable HEROKU_LEGACY_SSO=1. Then, run heroku login to log in directly from the CLI. Note, that this method is the only one available for headless SSO login.

FAQ: My Heroku account under SSO

Q: What if an employee leaves the company? How does the admin access the former employee’s personal apps?

A: The admin can log in as the user and transfer the apps.

Q: If a user upgrades auth to SSO and the IdP itself is disconnected by the admin at a future time, can the user log into their account?

A: Provided you still have access to your company email, you can reset your Heroku password in the normal way, and access your account.

Q: Can I disconnect my account from SSO?

A: No. After you upgrade your authentication and connect to an organization’s IdP, only the IdP admin can disconnect your account from SSO.

Q: How long does my SSO session last on Heroku?

A: An SSO session lasts 8 hours. After 8 hours, you will be prompted to login again.

Q: I already have a Heroku account with permissions on a team or Enterprise Account. Will signing in via SSO change my permissions on that Team / Enterprise Account?

A: In most cases, logging in via SSO with an existing Heroku account won’t change your permissions on the Team or Enterprise Account.

The exception is if you’re a collaborator. If a collaborator signs in with SSO to a team they get assigned the default role, not collaborator. The default role for a team is specified by an admin in the SSO section of the team’s Settings tab. See Using Single Sign-On (SSO) Services with Heroku, for Administrators for details.

The default SSO permission level for Enterprise Accounts is view and is not configurable. If you already have a Heroku account with permissions on an Enterprise Account, logging in via SSO will not change your permissions in any scenario.

Q: Am I required to enable multi-factor authentication (MFA) when using SSO?

A: Yes, you must enable MFA to ensure compliance with the company’s security and governance policies. When logging in via SSO, you must enable MFA with your identity provider instead of using the platform’s native MFA feature.

Keep reading

  • Single Sign-on (SSO)

Feedback

Log in to submit feedback.

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