Microsoftbeginner

WSL curl: Command Not Found - How to Fix

Fix the curl command not found error in Windows Subsystem for Linux (WSL). Learn how to install curl on Ubuntu, Debian, and other WSL distributions with step-by-step instructions.

4 min readUpdated January 2026

Want us to handle this for you?

Get expert help →

Getting a "curl: command not found" error in WSL (Windows Subsystem for Linux)? This guide shows you how to install curl on different Linux distributions running in WSL.

Quick Fix for Ubuntu/Debian WSL

Run this command in your WSL terminal:

sudo apt update && sudo apt install curl -y

That's it! Curl is now installed. Verify with:

curl --version

Why Is Curl Not Found?

Common reasons for the error:

  1. Minimal installation - Some WSL images don't include curl by default
  2. Fresh WSL instance - New installations have limited packages
  3. Lightweight distro - Alpine and minimal images exclude curl
  4. PATH issues - Rare, but possible if system configuration is modified

Install curl by Distribution

Ubuntu / Debian / Linux Mint

sudo apt update
sudo apt install curl -y

Fedora

sudo dnf install curl -y

Alpine Linux

apk update
apk add curl

Arch Linux

sudo pacman -S curl

openSUSE

sudo zypper install curl

CentOS / RHEL / Rocky Linux

# CentOS 8+ / Rocky / Alma
sudo dnf install curl -y

# CentOS 7
sudo yum install curl -y

Verify Installation

After installing, verify curl works:

# Check version
curl --version

# Check location
which curl

# Test with a request
curl -I https://example.com

Expected output:

curl 7.81.0 (x86_64-pc-linux-gnu) libcurl/7.81.0 OpenSSL/3.0.2 zlib/1.2.11 ...
Protocols: dict file ftp ftps gopher gophers http https ...
Features: alt-svc AsynchDNS brotli GSS-API HSTS HTTP2 ...

Troubleshooting

Permission Denied

If you get "permission denied" errors:

# Make sure you're using sudo
sudo apt install curl

Package Not Found

If apt can't find curl:

# Update package lists first
sudo apt update

# Then install
sudo apt install curl

Still Getting "Command Not Found" After Installing

Check if PATH is correct:

# See where curl is installed
whereis curl

# Check current PATH
echo $PATH

# Try running with full path
/usr/bin/curl --version

If curl is installed but not in PATH, add it to your ~/.bashrc:

export PATH=$PATH:/usr/bin

Then reload:

source ~/.bashrc

WSL Not Starting / Network Issues

If WSL has network problems:

# In PowerShell (as Administrator)
wsl --shutdown
wsl

Alternative: Use wget Instead

If you can't install curl, wget is often pre-installed and works similarly:

# Check if wget is available
wget --version

# Download a file
wget https://example.com/file.zip

# Make a request (similar to curl)
wget -qO- https://api.example.com/data

Install wget if needed:

sudo apt install wget -y

Using Windows curl from WSL

Windows 10/11 includes curl.exe. You can call it from WSL:

# Call Windows curl from WSL
curl.exe --version

# Make a request with Windows curl
curl.exe https://example.com

However, this isn't recommended as:

  • Different behavior from Linux curl
  • Line ending issues (CRLF vs LF)
  • May not support all Linux curl options

Install the Linux version for best compatibility.


Common curl Commands

Once installed, here are useful curl commands:

# Download a file
curl -O https://example.com/file.zip

# Download and save with custom name
curl -o myfile.zip https://example.com/file.zip

# Follow redirects
curl -L https://example.com/redirect

# Show response headers only
curl -I https://example.com

# Send POST request with JSON
curl -X POST -H "Content-Type: application/json" \
  -d '{"key":"value"}' https://api.example.com/data

# Include response headers in output
curl -i https://example.com

# Silent mode (no progress bar)
curl -s https://example.com

# Verbose output (debugging)
curl -v https://example.com

Summary

To fix "curl: command not found" in WSL:

  1. Ubuntu/Debian: sudo apt update && sudo apt install curl -y
  2. Fedora: sudo dnf install curl -y
  3. Alpine: apk add curl
  4. Arch: sudo pacman -S curl

Verify with curl --version after installation.

Frequently Asked Questions

Find answers to common questions

Curl may not be installed by default in minimal WSL installations. Some Linux distributions ship without curl to reduce image size. Additionally, if you're using a fresh WSL instance or a lightweight distribution, common utilities like curl need to be installed manually.

Struggling with Microsoft Updates?

Let our team handle Windows patching, updates, and system management so you can focus on your business.