> ## Content Index
> Fetch the complete content index at: https://blog.esadax.com/llms.txt
> Use this file to discover other available public pages before exploring further.

# How to Clear DNS Cache on Different Operating Systems
- URL: https://blog.esadax.com/en/how-to-clear-dns-cache-on-different-operating-systems-2/
- Published: 2025-04-20T00:00:00.000Z
- Updated: 2026-11-15T05:27:56.000Z
- Author: Esadax 
- Tags: #tr-domains-02-dns-01-intro-13-how-to-clear-the-local-dns-cache, #en, #mdx-imported, Domains

Clearing the DNS cache can help resolve issues like slow internet or incorrect domain resolutions. Below are step-by-step instructions for clearing the DNS cache on various operating systems.

---

## Introduction

DNS (Domain Name System) cache stores information about domain names and their corresponding IP addresses. Over time, this cache can become outdated or corrupted, leading to issues like slow internet speeds or incorrect domain resolutions. Clearing the DNS cache can help restore proper network functionality.

---

## macOS

On macOS Monterey (and newer), you can flush the DNS cache using the following command:

1. **Open Terminal**: Open your terminal application.
2. This will clear the DNS cache on your system.

**Flush DNS Cache**: Run the command:

```bash
sudo networksetup flushDNS

```

**Note**: After clearing the cache, test your internet connection to ensure it resolves correctly.

---

## Linux

On Linux, there are multiple ways to clear the DNS cache:

### Method 1: Using NSCD

- This will flush the DNS cache on your system.

Restart the NSCD service:

```bash
sudo /etc/init.d/nscd restart

```

**Verification**: Check if the cache is cleared by running:

```bash
sudo nslookup google.com

```

Look for "Server: 10.100.0.1" to confirm flushing.

### Method 2: Using systemd-resolve

Verify cache status by running:

```bash
sudo systemd-resolve --statistics

```

Look for "Current Cache Size" to confirm flushing.

Flush the cache with:

```bash
sudo systemd-resolve --flush-caches

```

---

## Windows

On Windows, you can clear the DNS cache using the `ipconfig` command:

1. **Open Command Prompt**:
  - For Windows 10/11: Right-click on the Start button and select "Command Prompt".
  - For earlier versions, click "All Programs > Accessories > Command Prompt" and run as Administrator.
2. This will clear your system's DNS cache.

**Flush DNS Cache**: Enter the following command:

```cmd
ipconfig /flushdns

```

---

## Additional Notes

- After clearing the cache, test your internet connection to ensure it resolves correctly.
- If issues persist, contact your network administrator or check if any cached data is needed for specific applications.

---