Home | Tech posts | Other posts | About me | Tech recommendations
- 13 Dec, 2025 *
A reader contacted me about how to achieve a .NET dev environment without admin access on Windows with the additional hurdle of not having permissions to run scripts. Naturally this makes things a bit more manual, but nonetheless easily achievable.
The key thing that the install script does is bui…
Home | Tech posts | Other posts | About me | Tech recommendations
- 13 Dec, 2025 *
A reader contacted me about how to achieve a .NET dev environment without admin access on Windows with the additional hurdle of not having permissions to run scripts. Naturally this makes things a bit more manual, but nonetheless easily achievable.
The key thing that the install script does is building a download url for the SDK based on the parameters given. A final url might be e.g. https://builds.dotnet.microsoft.com/dotnet/Sdk/10.0.101/dotnet-sdk-10.0.101-win-x64.zip
So to do the whole thing manually:
- Set the PATH and DOTNET_ROOT environment variables to the directory where you want to store the SDKs
$dotnetPath = "D:\dotnet"
[System.Environment]::SetEnvironmentVariable("DOTNET_ROOT", $dotnetPath, "User")
$currentPath = [System.Environment]::GetEnvironmentVariable("PATH", "User")
if ($currentPath -notlike "*$dotnetPath*") {
$newPath = $currentPath + ";" + $dotnetPath
[System.Environment]::SetEnvironmentVariable("PATH", $newPath, "User")
}
- build the download url yourself by substituting the version in the above url with the one you want (see e.g. https://versionsof.net/core/ for a list of current latest versions)
- download it directly, smuggle it in via a USB stick... Do whatever you can to get the zip to the local machine
- extract the zip to DOTNET_ROOT
- if you want to be fancy, check how the installation script decides which files to extract and what to leave as is.
- if you’re installing many sdk versions, e.g. the latest 6, 8 and 10, install the 10 last so all of the static files (such as dotnet.exe) are the latest and greatest available
- restart the terminal and verify installation with
dotnet --version
And please note that the installation scripts linked are probably considered ‘internal’, as is the download url currently used, so they may break at any point. Check the current script definition if this happens.
The original post has consistently been one of my most read, so there clearly is a need for this kind of lightweight SDK management. Hopefully MS will properly support this sooner rather than later, but until then, we’ll make do.
Thoughts, comments? Send me an email!