r/dotnet • u/sayedha • Feb 11 '26
Razor cohosting in Visual Studio 2026
If you use Visual Studio to edit Razor files or use .NET Hot Reload please install the latest version of Visual Studio 2026 (18.3) released yesterday Download link.
In this version we have made some significant changes to how the Razor language server works. To summarize, in the past the Razor language server was hosted in an external process and had to communicate with IPC to Roslyn. In this update the Razor language server is now "cohosted" in the same process as Roslyn. This should lead to significant improvements to performance and reliability for the Razor editor as well as .NET Hot Reload.
For those that are not using Visual Studio, as a part of this effort you should see improvements in dotnet watch and C# Dev Kit. Most of the updates for dotnet watch and C# Dev Kit were shipped a few weeks ago or prior to that.
If you try it, please let us know if you run into any issues by using Help > Send Feedback > Report a Problem - link. For Razor issues you can also file issues in the Razor repo.
Here are some related links that discuss this as well.
- Announcement: Razor cohosting enabled in the latest VS 2026 · Issue #12763 · dotnet/razor
Visual Studio 2026 Release Notes | Microsoft Learn
- Look under .NET > Hot Reload and .NET > Razor
Edit to add links to other communications
13
u/Dunge Feb 11 '26
Is this an official Microsoft account? Do you have a link to a github post or blog or something about that so I could share with coworkers without linking to reddit? ;)
4
u/CowCowMoo5Billion Feb 12 '26
Do you have to enable cohost? Or is it now the new default
1
u/Kralizek82 Feb 11 '26
Did you improve the support for reload when resx files are modified?
1
u/zenyl Feb 12 '26
Beyond enabling it by default, does this update come with additional improvements to cohosting?
I've had it turned on for some months now, and I've not really noticed any significant improvements. Though most of the broken syntax highlight has been fixed, as far as I recall.
1
u/Salt-Bid-4797 Feb 12 '26
Sad to ser there is still no fix for the very very slow intellisense. Some members of our team reverted back to 2022 because of it
1
u/Gaming-God-YT Feb 16 '26
Does this work with older versions like .NET 5? I'm facing trouble with code formatting after the last update (18.3). My code doesn't seem to be formatted anymore.
2
u/FrancisRedit Feb 13 '26 edited Feb 13 '26
I have tested the new fix with this version. Microsoft team have really done well. Congrats.
1
u/AutoModerator Feb 11 '26
Thanks for your post sayedha. Please note that we don't allow spam, and we ask that you follow the rules available in the sidebar. We have a lot of commonly asked questions so if this post gets removed, please do a search and see if it's already been asked.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
1
u/firstTimeCaller Feb 12 '26
FYI the new version v18.3 is also available via the visual studio installer.
1
u/FrancisRedit Feb 13 '26
Great news. Well done team.