Create a new Heroku source in Better Stack. We recommend having separate telemetry sources for each of your applications in Heroku.
Install the Heroku CLI.
Log in to Heroku:
Set up Better Stack drain to Heroku:
You will need to replace $HEROKU_APP_SLUG in the command above. The application slug is the name of the application in Heroku. You can see your available apps in the Heroku dashboard.
Heroku's next-generation Fir uses OpenTelemetry drains instead of the Logplex drains used in Cedar. Follow Send telemetry from Heroku Fir apps to send logs, metrics, and traces to Better Stack in Fir.
You should see your logs in Better Stack β Live tail.
Check out your metrics in the Heroku dashboard.
Enable Heroku Runtime Metrics to take full advantage of our Heroku dashboard.
Use Heroku CLI to set up metrics for your app:
You will need to replace $HEROKU_APP_SLUG in the commands above. The application slug is the name of the application in Heroku. You can see your available apps in the Heroku dashboard.
Send logs, metrics, and traces to Better Stack using an OpenTelemetry drain in Heroku Fir.
Create a Heroku source in Better Stack.
Send your Fir app's telemetry to the source:
Replace $HEROKU_APP_SLUG with your application slug. It is the name of the application in Heroku, listed in the Heroku dashboard.
Add the drain to the space instead of running the app command above. Every app in the space sends its telemetry to Better Stack, including apps you create later:
Replace $HEROKU_SPACE with the name of your space. Run heroku spaces to list your spaces.
You should see your logs and traces in Better Stack β Live tail.
Please let us know at hello@betterstack.com.
We're happy to help! π
Interested in best practices for logging in Heroku? Check out our Complete Guide to Logging in Heroku.
We use cookies to authenticate users, improve the product user experience, and for personalized ads. Learn more.