How to Search for Files Ignoring Case Sensitivity in Ubuntu (find -iname)

The Case-Sensitive Nightmare

Unlike Windows, the Ubuntu Linux file system is strictly case-sensitive. This means that invoice.pdf, Invoice.pdf, and INVOICE.PDF are considered three completely different files that can exist simultaneously in the exact same folder. If you are searching a massive shared network drive for a document, but you don’t know whether the user capitalized the first letter, using the standard find -name command will fail entirely unless you guess the exact capitalization. To guarantee you find the file regardless of how it was typed, you must instruct the search engine to ignore case.

Using the find Command with -iname

The Linux find command utilizes the -iname (case-insensitive name) flag to search the file system while completely ignoring uppercase and lowercase distinctions.

  1. Open your Terminal application (Ctrl + Alt + T) or log into your server via SSH.
  2. To scan your entire home directory for a file named “report.txt” (regardless of capitalization), type the following command exactly:
  3. find ~/ -type f -iname "report.txt"
  4. Press Enter.

Failsafe Searching

The search engine will recursively dig through your home folder and output the absolute path of every file that matches the letters, returning Report.txt, REPORT.TXT, and rEpOrT.tXt simultaneously. This flag is especially critical when combined with wildcards (e.g., -iname "*.jpg") because older digital cameras often save photos with a capitalized .JPG extension, while modern web scripts use lowercase .jpg. Using -iname guarantees that you never miss a file due to a simple capitalization error.

Get the best tech tips delivered straight to your inbox.

Join thousands of readers mastering Apple, Google, Microsoft, and Linux.