A Chainlit application can be consumed through multiple platforms. Write your assistant logic once, use everywhere!

Available Platforms

Deploy your Chainlit Application

No matter the platform(s) you want to serve with your Chainlit application, you will need to deploy it first.

After you’ve successfully set up and tested your Chainlit application locally, the next step is to make it accessible to a wider audience by deploying it to a hosting service. This guide provides various options for self-hosting your Chainlit app.

When running a Chainlit app in production, you should always add -h to the chainlit run command. Otherwise a browser window will be opened server side and might break your deployment.

Chainlit is built upon websockets, which means the service you deploy your app to has to support them. For auto scaling, make sure to enable sticky sessions.

If you need to deploy your Chainlit app to a subpath like https://my-app.com/chainlit, you will need to set the --root-path /chainlit flag when running the chainlit run command. This will ensure that the app is served from the correct path.