Error: listen tcp 127.0.0.1:11434: bind: Only one usage of each socket address (protocol/network address/port) is normally permitted. — another Ollama server already owns port 11434, usually the one the Ollama app started for you. You do not need ollama serve: ollama list, ollama run and your own code already talk to that server.

If you do want a second server, give it its own port with OLLAMA_HOST. If you want to run the only server by hand, quit the Ollama app from its tray icon first and check that 11434 is free.

The error

PS> ollama serve
Error: listen tcp 127.0.0.1:11434: bind: Only one usage of each socket address (protocol/network address/port) is normally permitted.

Why it happens

On Windows, Ollama installs a tray app, ollama app.exe, and the app starts the server as its own child process, ollama.exe serve, listening on 127.0.0.1:11434. Typing ollama serve yourself starts a second server that asks for the same address and port, and only one program may listen on a given address and port at a time. The app's server is easy to miss because it has no window.

The wording is Windows' own text for socket error WSAEADDRINUSE (10048), which is why it reads nothing like the Linux version. The same collision inside WSL, where Ollama runs as a systemd service, printed Error: listen tcp 127.0.0.1:11434: bind: address already in use. Both mean the port is taken; neither means Ollama is broken.

The fix

First see who owns the port, then use that server:

PS> Get-NetTCPConnection -LocalPort 11434 -State Listen | Select-Object LocalAddress, LocalPort, OwningProcess

LocalAddress LocalPort OwningProcess
------------ --------- -------------
127.0.0.1        11434         29292

PS> Get-CimInstance Win32_Process -Filter "Name like 'ollama%'" | Select-Object ProcessId, ParentProcessId, Name

ProcessId ParentProcessId Name
--------- --------------- ----
    29516            2388 ollama app.exe
    29292           29516 ollama.exe

PS> ollama list
NAME                       ID              SIZE      MODIFIED
qwen2.5:14b                7cdf5a0187d5    9.0 GB    6 days ago
...
PS> Invoke-RestMethod http://127.0.0.1:11434/api/version

version : 0.34.2

Process 29292 holds the port and its parent is the tray app. The model list (trimmed here) and the API both answered, so nothing needed starting. For a second server alongside it:

PS> $env:OLLAMA_HOST = "127.0.0.1:11435"
PS> $env:OLLAMA_NOPRUNE = "1"
PS> ollama serve
... msg="Listening on 127.0.0.1:11435 (version 0.34.2)"

Clients reach it only with the same OLLAMA_HOST set; ollama list and /api/version on port 11435 both answered. Both servers use the same model folder by default, so OLLAMA_NOPRUNE (described by ollama serve --help as "Do not prune model blobs on startup") leaves that folder's upkeep to the first server. Variables set with $env: last only for that window.

How it was reproduced

Ollama for Windows 0.34.2 on Windows 11, with the tray app running. Running ollama serve from PowerShell exited at once with code 1 and the message above, leaving the tray app's server untouched. The Linux wording came from Ollama 0.34.2 in Ubuntu 24.04 under WSL, where the systemd service held the port. The second server was started with Start-Process under the two environment variables, checked, and stopped; quitting the tray app was not exercised because that server was not ours to stop.

Frequently asked

Do I need to run ollama serve on Windows?
Not while the Ollama app is running. The app starts its own server on 127.0.0.1:11434, and ollama list, ollama run and ollama ps talk to it. Run ollama serve by hand only after quitting the app, or on another port.
How do I find what is using port 11434 on Windows?
Run Get-NetTCPConnection -LocalPort 11434 -State Listen in PowerShell and read OwningProcess, then look that id up with Get-Process or Get-CimInstance Win32_Process. On Linux, ss -ltn shows the listener.
How do I run two Ollama servers on one machine?
Start the second with OLLAMA_HOST set to another port, such as 127.0.0.1:11435, and set the same OLLAMA_HOST for any client that should use it. Setting OLLAMA_NOPRUNE=1 stops the second server pruning the shared model folder on startup.

More decoded errors in the Fixes category, or see Ollama installed and first run on Windows in season four, Part 1.