In this video, i am going to show you how to set up the database connection and connect to a SQL Server database in an ASP.NET Core application. First, create a new project and give any name. Make sure to tick configure for https. If you are creating a web application project with login and you want to include the http post method, then uncheck the configure for https. After that, click on create. Make sure to install the packages. Don't forget to create database in sql server. After creating database in sql server go to appsettings.json and mention the connectionStrings. Give a name of the connection such as defaultconnection. Copy and paste the server name in server. Once done, create two classes in models. First one will be users, second one will be the dbcontext class(UsersDbContext) After done with classes, register the db context class in program.cs. Don't forget to save all. Finally, make migration and update-database. If no error occurs during migration and updating database, then you are going to see the migration and the table name in sql server management studio. Thanks. Please like and subscribe :)