Skip to main content
net8.0net9.0

An Aspire hosting integration for providing a Sqlite database connection.

Published
Mar 19, 2025
1y ago
Total Downloads
98.5K
98,478

Install

dotnet add package CommunityToolkit.Aspire.Hosting.Sqlite --version 9.3.0
ProductVersions
.NET
net8.0net9.0

README

CommunityToolkit.Aspire.Hosting.Sqlite library

Provides extension methods and resource definitions for the .NET Aspire AppHost to support creating and running SQLite databases.

The integration also provides support for running SQLite Web to interact with the SQLite database.

By default, the Sqlite resource will create a new SQLite database in a temporary location. You can also specify a path to an existing SQLite database file.

Getting Started

Install the package

In your AppHost project, install the package using the following command:

dotnet add package CommunityToolkit.Aspire.Hosting.Sqlite

Example usage

Then, in the Program.cs file of AppHost, define an Sqlite resource, then call AddSqlite:

var sqlite = builder.AddSqlite("sqlite")
    .WithSqliteWeb();

Additional Information

https://learn.microsoft.com/dotnet/aspire/community-toolkit/sqlite

Feedback & contributing

https://github.com/CommunityToolkit/Aspire

Changes from Previous Version

No structural changes between v9.3.0-beta.239 and v9.3.0.

Adoption Assessment

A verified publisher signal is available. Assess fit from the package's supported frameworks, license and dependency graph rather than popularity alone.

Compatibility metadata lists 2 target frameworks; confirm the exact target used by your application.

Related Guides & Workflows

Learn how to evaluate, integrate, or audit this package in your .NET project.