File Name Sanitizer
Sanitize file names by stripping invalid characters and spaces.
File Utilities & Newline Converter
About File Name Sanitizer
The Cross-Platform File Name & Path Sanitizer cleans illegal characters (`/`, `\`, `:`, `*`, `?`, `"`, `<`, `>`, `|`), emoji symbols, non-ASCII letters, and Windows reserved names (`CON`, `PRN`, `AUX`, `NUL`) to guarantee filesystem portability.
How to Use File Name Sanitizer
Step 1
Paste one or more filenames into the input area.
Step 2
Select filesystem target (Windows Safe, POSIX, or Web URL Slug).
Step 3
Choose replacement character for invalid symbols (Hyphen `-` or Underscore `_`).
Step 4
Click "Copy Sanitized Names".
Practical Use Cases for File Name Sanitizer
Preparing File Lists for Cross-Platform Cloud Storage
Sanitize file names so files created on macOS/Linux can be safely extracted and opened on Windows machines without filesystem errors.
Web Asset & URL Slug Generation
Convert document titles with spaces and accents (e.g. `Résumé 2024 (Final)!.pdf`) into safe web assets (`resume-2024-final.pdf`).
Input & Output Examples
Sanitizing Illegal Windows Filename
Filename: "Report: Q1/Q2 <Draft> *Final*.docx"
Sanitized: "Report_ Q1_Q2 _Draft_ _Final_.docx" (or URL Slug: "report-q1-q2-draft-final.docx")
Key Features & Performance
- ✓Removes forbidden characters across Windows, Linux, macOS, POSIX, and Web URL standards.
- ✓Detects Windows reserved device names (`CON`, `PRN`, `AUX`, `NUL`, `COM1-9`, `LPT1-9`).
- ✓Normalization styles: Underscores, Hyphens, CamelCase, or URL-safe ASCII slug.
- ✓100% Client-Side memory execution.
- ✓1-Click Copy sanitized name.
Key Terminology & Definitions
Illegal Filename Characters
Characters prohibited by OS filesystem drivers (e.g. Windows forbids `\ / : * ? " < > |` and control characters `0–31`).
Windows Reserved Device Names
Legacy MS-DOS device names (like `CON`, `NUL`, `AUX`) that cannot be used as filenames in Windows regardless of extension.
