Search for large files and folders using ncdu

By EssingtonITS team ·

Learn how to use ncdu, a text-based disk utility for Unix systems, to identify and manage large files and folders. It offers a user-friendly interface and options for exporting data in JSON format.

ncdu: NCurses Disk Usage

ncdu (NCurses Disk Usage) is a disk utility for Unix systems. It serves a similar purpose to the du utility but features a text-based user interface via the curses programming library. Users can navigate the list using the arrow keys and delete files that are taking up too much space by pressing the 'd' key. From version 1.09 onwards, ncdu can export the file listing in JSON format.

The ncdu package is available in distribution repositories like Debian, Ubuntu, Linux Mint, and their derivatives.

Installation on Ubuntu

apt-get update
apt-get install ncdu

Usage

ncdu <options> <directory>

Options

  • -h: This help message
  • -q: Quiet mode, refresh interval 2 seconds
  • -v: Print version
  • -x: Same filesystem
  • -r: Read only
  • -o FILE: Export scanned directory to FILE
  • -f FILE: Import scanned directory from FILE
  • -0,-1,-2: UI to use when scanning (0=none, 2=full ncurses)
  • --si: Use base 10 (SI) prefixes instead of base 2
  • --exclude PATTERN: Exclude files that match PATTERN
  • -X, --exclude-from FILE: Exclude files that match any pattern in FILE
  • --exclude-caches: Exclude directories containing CACHEDIR.TAG
  • --confirm-quit: Confirm quitting ncdu

A terminal window displaying disk usage analysis with a highlighted directory

For more information, visit the ncdu official website.

Looking to enhance your Linux infrastructure? At EssingtonITS.co.uk, we offer expert support and tailored solutions to optimise your systems. Let us help you achieve seamless integration and improved performance.

person people found this useful.

Related

Knowledge base 10 Jun 2026

Personal Notebook in eLLM

The personal notebook in eLLM allows users to organise and store notes, images, and files in a private, searchable timeline. It ensures privacy by keeping contents visible only to the user, and it can be integrated with the assistant for personalised answers.

Knowledge base 9 Jun 2026

Git Commands Quick Reference Guide

This quick reference guide covers essential Git commands for repository setup, staging, branching, merging, and working with remote repositories, making it a handy tool for developers to streamline their workflow.

Knowledge base 9 Jun 2026

Organisation Skills in the eLLM Admin Console

The article explains how the eLLM Admin Console allows organisations to create and manage shared instruction sets called "organisation skills" to ensure consistent responses across teams. These skills can be customised, restricted to specific groups, and integrated with extern…

Expand 29 Jul 2026

How AI can support pupils with SEND

Explore how AI tools are aiding pupils with special educational needs and disabilities by simplifying text, breaking down tasks, and enhancing accessibility. Learn about the considerations schools should make before implementation.

Expand 29 Jul 2026

AI policy and practice in further education

Further education colleges need distinct AI policies due to their unique mix of vocational courses, diverse age groups, and specific funding and inspection requirements. This guidance highlights the importance of tailored AI approaches in FE settings.