Login Register
Code2night
  • Home
  • Blog Archive
  • Tutorial
  • Interview Q&A
  • Languages
    • Angular
    • C
    • c#
    • C#
    • HTML/CSS
    • Java
    • JavaScript
    • Node.js
    • Python
    • React
    • Security
    • SQL Server
    • TypeScript
  • Post Blog
  • Tools
    • JSON Beautifier
    • HTML Beautifier
    • XML Beautifier
    • CSS Beautifier
    • JS Beautifier
    • PDF Editor
    • Word Counter
    • Base64 Encode/Decode
    • Diff Checker
    • JSON to CSV
    • Password Generator
    • SEO Analyzer
    • Background Remover
  1. Home
  2. Blog
  3. How to Fix Visual Studio Not Refreshing Changes in Browser

How to Fix Visual Studio Not Refreshing Changes in Browser

Date- Jun 09,2021

8982

Net Core Visual Studio

Issue with .Net core 3.1

So, this issue mainly comes while working with .Net core. However solutions can be bit different in earlier versions of .Net core and after version 3.1. So we will see how to fix that for .Net core 3.1. 

First of all, for fixing this issue we have to add a missing NuGet package in our project. For that , navigate to 

Project ->Manage NuGet Packages  

as shown in the image below :-

Now you have to find a package named Microsoft.AspNetCore.Mvc.Razor.RuntimeCompilation . You can have a look at the image below.

So, for avoiding compatibility issues we will be using slightly older version for this. As you can see we have used version 3 for this. After selecting that version, click on Install.


Now after your installation is completed . You can move to the last step. You have to add two lines in ConfigureServices Method.You can see in the screenshot below. Add this line to your startup.cs.

IMvcBuilder builder = services.AddRazorPages();
builder.AddRazorRuntimeCompilation();

After adding these lines, now just rebuild your project and run. And this time your changes will be refreshed on browser reload. So this is how we can fix visual studio reload issue in .Net core 3.1.

S
Shubham Batra
Programming author at Code2Night โ€” sharing tutorials on ASP.NET, C#, and more.
View all posts โ†’

Related Articles

How to Master Async and Await in C#: Complete Guide
Mar 16, 2026
Introduction to C# Programming: Your First Steps in Software Development
Mar 08, 2026
Get random number in asp.net C#
Dec 23, 2023
How to Publish in Local Folder with .NET: Step-by-Step
Dec 09, 2023
Previous in ASP.NET Core
Globalization and Localization in ASP.NET Core with Resource File…
Next in ASP.NET Core
Real-Time Chat Made Easy: SignalR with .NET Core and Vue.js

Comments

Contents

๐ŸŽฏ

Interview Prep

Ace your ASP.NET Core interview with curated Q&As for all levels.

View ASP.NET Core Interview Q&As

More in ASP.NET Core

  • How to Encrypt and Decrypt Passwords in ASP.NET: A Guide 25945 views
  • Exception Handling in ASP.NET Core: Best Practices 20720 views
  • HTTP Error 500.31: Failed to Load ASP.NET Core Runtime 20200 views
  • How to Implement PayPal in ASP.NET Core: Ultimate Guide 19611 views
  • Task Scheduling Made Easy in ASP.NET Core: Step-by-Step 17502 views
View all ASP.NET Core posts โ†’

Tags

AspNet C# programming AspNet MVC c programming AspNet Core C software development tutorial MVC memory management Paypal coding coding best practices data structures programming tutorial tutorials object oriented programming Slick Slider StripeNet
Free Download for Youtube Subscribers!

First click on Subscribe Now and then subscribe the channel and come back here.
Then Click on "Verify and Download" button for download link

Subscribe Now | 1760
Download
Support Us....!

Please Subscribe to support us

Thank you for Downloading....!

Please Subscribe to support us

Continue with Downloading
Be a Member
Join Us On Whatsapp
Code2Night

A community platform for sharing programming knowledge, tutorials, and blogs. Learn, write, and grow with developers worldwide.

Panipat, Haryana, India
info@code2night.com
Quick Links
  • Home
  • Blog Archive
  • Tutorials
  • About Us
  • Contact
  • Privacy Policy
  • Terms & Conditions
  • Guest Posts
  • SEO Analyzer
Free Dev Tools
  • JSON Beautifier
  • HTML Beautifier
  • CSS Beautifier
  • JS Beautifier
  • Password Generator
  • QR Code Generator
  • Hash Generator
  • Diff Checker
  • Base64 Encode/Decode
  • Word Counter
  • SEO Analyzer
By Language
  • Angular
  • C
  • c#
  • C#
  • HTML/CSS
  • Java
  • JavaScript
  • Node.js
  • Python
  • React
  • Security
  • SQL Server
  • TypeScript
© 2026 Code2Night. All Rights Reserved.
Made with for developers  |  Privacy  ยท  Terms
Translate Page
We use cookies to improve your experience and analyze site traffic. By clicking Accept, you consent to our use of cookies. Privacy Policy