Azure Table Storage In ASP.NET Core 2.0


How to use Azure Table storage in ASP.NET Core.


Create a class library and add NuGet package: WindowsAzure.Storage

Add a class to encapsulate the settings.

Add a class to encapsulate the storage access. Add a private helper method to access the storage.

Now, add public methods for the storage.

Inject and use storage

In ASP.NET Core Web application, configure services.


The sample code will require you to setup Azure account, storage account, and table. Instructions for these could be found here.

Source Code