[GH-ISSUE #2546] (windows), HOW TO INSTALL IT on DIFFERENT drives than C???? #1490

Closed
opened 2026-04-12 11:23:52 -05:00 by GiteaMirror · 10 comments
Owner

Originally created by @APISeeker on GitHub (Feb 16, 2024).
Original GitHub issue: https://github.com/ollama/ollama/issues/2546

Originally assigned to: @dhiltgen on GitHub.

Hello
I tried installing it by cliking on the window installer
It started by inserting some ddl files in C ok, but then even the models are inserted there:
image

I dont have much space left
I would like the option to install ollama outside C:/ or at least have the modesl outside that, in another path.

Is that possible?

Thanks

Originally created by @APISeeker on GitHub (Feb 16, 2024). Original GitHub issue: https://github.com/ollama/ollama/issues/2546 Originally assigned to: @dhiltgen on GitHub. Hello I tried installing it by cliking on the window installer It started by inserting some ddl files in C ok, but then even the models are inserted there: ![image](https://github.com/ollama/ollama/assets/145594487/25fd6be6-50f2-4924-87be-f990ef7f3728) I dont have much space left I would like the option to install ollama outside C:/ or at least have the modesl outside that, in another path. Is that possible? Thanks
Author
Owner

@MartynKeigher commented on GitHub (Feb 16, 2024):

Let it install on your C drive... and then read #2551! :)

<!-- gh-comment-id:1949342989 --> @MartynKeigher commented on GitHub (Feb 16, 2024): Let it install on your C drive... and then read #2551! :)
Author
Owner

@ninjanimus commented on GitHub (Feb 18, 2024):

For those the custom path is not considered even after adding OLLAMA_MODELS environment variable and restarting the Terminal. Try restarting the OS once, then it is working. Might be the environment variables are stored in memory of the running Ollama process.

<!-- gh-comment-id:1951183771 --> @ninjanimus commented on GitHub (Feb 18, 2024): For those the custom path is not considered even after adding OLLAMA_MODELS environment variable and restarting the Terminal. Try restarting the OS once, then it is working. Might be the environment variables are stored in memory of the running Ollama process.
Author
Owner

@dhiltgen commented on GitHub (Feb 19, 2024):

While a reboot will work, you should only have to quit the tray app after setting the OLLAMA_MODELS environment variable in your account. Get a fresh terminal, and run ollama run llama2 (or equivalent) and it will relaunch the tray app, which in turn will relaunch the server which should pick up the new models directory.

<!-- gh-comment-id:1953155187 --> @dhiltgen commented on GitHub (Feb 19, 2024): While a reboot will work, you should only have to quit the tray app after setting the OLLAMA_MODELS environment variable in your account. Get a fresh terminal, and run `ollama run llama2` (or equivalent) and it will relaunch the tray app, which in turn will relaunch the server which should pick up the new models directory.
Author
Owner

@Shishir3k commented on GitHub (Nov 17, 2024):

After Istalling Ollama follow these steps to store llms in different drive than C :

  1. First Quit Ollama by clicking on it in the task bar.

  2. Start the Settings (Windows 11) or Control Panel (Windows 10) application and search for environment variables.

  3. Click on Edit environment variables for your account.

  4. Edit or create a new variable for your user account for OLLAMA_HOST, OLLAMA_MODELS, etc.

  5. Click OK/Apply to save.

  6. Start the Ollama application from the Windows Start menu.

<!-- gh-comment-id:2480904779 --> @Shishir3k commented on GitHub (Nov 17, 2024): After Istalling Ollama follow these steps to store llms in different drive than C : 1. First Quit Ollama by clicking on it in the task bar. 2. Start the Settings (Windows 11) or Control Panel (Windows 10) application and search for environment variables. 3. Click on Edit environment variables for your account. 4. Edit or create a new variable for your user account for OLLAMA_HOST, OLLAMA_MODELS, etc. 5. Click OK/Apply to save. 6. Start the Ollama application from the Windows Start menu.
Author
Owner

@Santhanam1 commented on GitHub (Nov 20, 2024):

Hello I tried installing it by cliking on the window installer It started by inserting some ddl files in C ok, but then even the models are inserted there: image

I dont have much space left I would like the option to install ollama outside C:/ or at least have the modesl outside that, in another path.

Is that possible?

Thanks

you can install in d drive by using this command in cmd " .\OllamaSetup.exe /DIR=D:\Your desired location "

<!-- gh-comment-id:2488081168 --> @Santhanam1 commented on GitHub (Nov 20, 2024): > Hello I tried installing it by cliking on the window installer It started by inserting some ddl files in C ok, but then even the models are inserted there: ![image](https://private-user-images.githubusercontent.com/145594487/305523643-25fd6be6-50f2-4924-87be-f990ef7f3728.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzIwOTU3NzMsIm5iZiI6MTczMjA5NTQ3MywicGF0aCI6Ii8xNDU1OTQ0ODcvMzA1NTIzNjQzLTI1ZmQ2YmU2LTUwZjItNDkyNC04N2JlLWY5OTBlZjdmMzcyOC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQxMTIwJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MTEyMFQwOTM3NTNaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wMjJlMDZlZTcyMjNhMTFlOGI4Y2NmZjgzZDRmYTRmNmFjMzIwNTQ1YWVhMWViMjYzOGU1NTU4OTFiNWMwNzA2JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.FemNzFR2tA4UXx3XtLE5KuK6EmPvtY7EuH8snjj3OSs) > > I dont have much space left I would like the option to install ollama outside C:/ or at least have the modesl outside that, in another path. > > Is that possible? > > Thanks you can install in d drive by using this command in cmd " .\OllamaSetup.exe /DIR=D:\Your desired location "
Author
Owner

@prophed1 commented on GitHub (Nov 26, 2024):

Hello I tried installing it by cliking on the window installer It started by inserting some ddl files in C ok, but then even the models are inserted there: image
I dont have much space left I would like the option to install ollama outside C:/ or at least have the modesl outside that, in another path.
Is that possible?
Thanks

you can install in d drive by using this command in cmd " .\OllamaSetup.exe /DIR=D:\Your desired location "

it works, thank you sir

<!-- gh-comment-id:2499648212 --> @prophed1 commented on GitHub (Nov 26, 2024): > > Hello I tried installing it by cliking on the window installer It started by inserting some ddl files in C ok, but then even the models are inserted there: ![image](https://private-user-images.githubusercontent.com/145594487/305523643-25fd6be6-50f2-4924-87be-f990ef7f3728.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzIwOTU3NzMsIm5iZiI6MTczMjA5NTQ3MywicGF0aCI6Ii8xNDU1OTQ0ODcvMzA1NTIzNjQzLTI1ZmQ2YmU2LTUwZjItNDkyNC04N2JlLWY5OTBlZjdmMzcyOC5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjQxMTIwJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI0MTEyMFQwOTM3NTNaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT0wMjJlMDZlZTcyMjNhMTFlOGI4Y2NmZjgzZDRmYTRmNmFjMzIwNTQ1YWVhMWViMjYzOGU1NTU4OTFiNWMwNzA2JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.FemNzFR2tA4UXx3XtLE5KuK6EmPvtY7EuH8snjj3OSs) > > I dont have much space left I would like the option to install ollama outside C:/ or at least have the modesl outside that, in another path. > > Is that possible? > > Thanks > > you can install in d drive by using this command in cmd " .\OllamaSetup.exe /DIR=D:\Your desired location " it works, thank you sir
Author
Owner

@hossamantarkorin commented on GitHub (Jan 25, 2025):

Just clarifying: Simply creating the Environment variable prior running the command to download the ollama model (e.g., ollama run deepseek-r1:14b) will result in the model being saved directly to the desired directory instead of having to shuffle it back from the C drive.

<!-- gh-comment-id:2613684016 --> @hossamantarkorin commented on GitHub (Jan 25, 2025): Just clarifying: Simply creating the Environment variable prior running the command to download the ollama model (e.g., ollama run deepseek-r1:14b) will result in the model being saved directly to the desired directory instead of having to shuffle it back from the C drive.
Author
Owner

@RAMPRASAD27 commented on GitHub (Jul 15, 2025):

After Istalling Ollama follow these steps to store llms in different drive than C :

  1. First Quit Ollama by clicking on it in the task bar.
  2. Start the Settings (Windows 11) or Control Panel (Windows 10) application and search for environment variables.
  3. Click on Edit environment variables for your account.
  4. Edit or create a new variable for your user account for OLLAMA_HOST, OLLAMA_MODELS, etc.
  5. Click OK/Apply to save.
  6. Start the Ollama application from the Windows Start menu.

Thankyou, It worked

<!-- gh-comment-id:3072760711 --> @RAMPRASAD27 commented on GitHub (Jul 15, 2025): > After Istalling Ollama follow these steps to store llms in different drive than C : > > 1. First Quit Ollama by clicking on it in the task bar. > 2. Start the Settings (Windows 11) or Control Panel (Windows 10) application and search for environment variables. > 3. Click on Edit environment variables for your account. > 4. Edit or create a new variable for your user account for OLLAMA_HOST, OLLAMA_MODELS, etc. > 5. Click OK/Apply to save. > 6. Start the Ollama application from the Windows Start menu. Thankyou, It worked
Author
Owner

@joelBrun commented on GitHub (Aug 2, 2025):

.\OllamaSetup.exe /DIR=D:\

Why is this not a simple parameter in the OllamaSetup.exe installer GUI ?

<!-- gh-comment-id:3146618518 --> @joelBrun commented on GitHub (Aug 2, 2025): > .\OllamaSetup.exe /DIR=D:\ Why is this not a simple parameter in the OllamaSetup.exe installer GUI ?
Author
Owner

@paeonn commented on GitHub (Aug 6, 2025):

.\OllamaSetup.exe /DIR=D:\

Why is this not a simple parameter in the OllamaSetup.exe installer GUI ?

Probably tooooo hard XD

<!-- gh-comment-id:3161125902 --> @paeonn commented on GitHub (Aug 6, 2025): > > .\OllamaSetup.exe /DIR=D:\ > > Why is this not a simple parameter in the OllamaSetup.exe installer GUI ? Probably tooooo hard XD
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/ollama#1490