### Add a database connection string Add a connection string to the *appsettings.json* file. [!code-json[Main](../../tutorials/razor-pages/razor-pages-start/sample/RazorPagesMovie/appsettings_SQLite.json?highlight=8-10)] ### Register the database context Register the database context with the [dependency injection](xref:fundamentals/dependency-injection) container in the *Startup.cs* file.