Overview
By default, Browserbase sessions have a timeout period after which they automatically terminate. You can extend this duration either project-wide or per-session. This is useful for long-running tasks, complex workflows, or any scenario where you need more time than the default allows.The maximum session duration is 6 hours. Once a session times out, it cannot be reused.
Project-Wide Timeout Settings
You can change the default session timeout for all sessions in your project through the dashboard settings.

Custom Session Timeout
For more control, set a custom timeout when creating individual sessions. This overrides the project default.- Node.js
- Python
Timeouts vs Keep Alive
Setting a custom timeout extends how long a session can run, but the session will still terminate when you disconnect. If you need to disconnect and reconnect to the same session, use Keep Alive instead. For sessions that need both extended duration and reconnection support, configure both options:Keep Alive
Learn how to keep sessions alive across disconnects.