Windows 10: File Explorer search does not correctly handle ~ character in filenames

Discus and support File Explorer search does not correctly handle ~ character in filenames in Windows 10 Software and Apps to solve the problem; Please fix the behavior of File Explorer search when using the tilde ~ character. This character is valid in filenames, but searching for ~ e.g., using... Discussion in 'Windows 10 Software and Apps' started by VitaliySmile, Jun 27, 2025 at 10:42 PM.

  1. File Explorer search does not correctly handle ~ character in filenames


    Please fix the behavior of File Explorer search when using the tilde ~ character. This character is valid in filenames, but searching for ~ e.g., using *~* returns unrelated results or behaves inconsistently. This causes confusion and makes it hard to find files with ~ in their names. It’s unacceptable that a valid character cannot be reliably searched for. Please address this issue.

    :)
     
  2. JeffCL Win User

    Searching for a string within a filename in File Explorer

    I want to search a folder for filenames that contain the word "Committee". When in File Explorer, I type "Committee" into the Search field and hit enter. It finds (highlights in yellow) files that start with "Committee" but not the ones where "Committee"
    is embedded in the file name. For example:

    • "Committee-Mission-Roles-and-Responsibilities" = finds it and highlights "Committee" in yellow
    • "19510701ListClubCommitteesReportDirectorsBW" = Lists this file but does not highlight "Committee" in yellow
    • "20150526MinutesBoard" = Lists this file because the word "Committee" is in the text of the file.
    Is there a way to do a search that lists only filenames that contain the word "Committee"? I don't want files listed if the word "Committee" is not part of the filename.

    Moved from ( Windows / Windows 10 / Files, folders, & storage )
     
  3. File Explorer not searching correctly.

    Hi

    Thanks for your reply.

    I understand the issue with your File Explorer's search function persists. It's indeed unusual that it only allows searching with a single character and crashes with two or more.

    I can suggest further troubleshooting steps.

    1. Reset File Explorer: Open Task Manager (Ctrl + Shift + Esc), find 'Windows Explorer', right-click it and select 'Restart'. This will reset File Explorer and might solve temporary glitches.
    2. Check Event Viewer: Event Viewer can provide more information about what's causing File Explorer to crash. Press Windows Key + X and select 'Event Viewer'. In the left panel, navigate to 'Windows Logs' > 'Application'. Look for recent events with 'Error' level. The 'General' tab in the lower half of the screen provides details about the error.
    3. Create a New User Account: Sometimes, user account files can get corrupted and cause issues. Creating a new user account can help determine if this is the case. If File Explorer works correctly on the new account, you might need to move your files to this new account and use it instead.
    Please keep me updated on your progress, and don't hesitate to ask if you have further questions or need more assistance.
     
    Derrick19 - MSFT, Jun 27, 2025 at 11:38 PM
    #3
  4. Kari Win User

    File Explorer search does not correctly handle ~ character in filenames

    How do I search for the % character

    As the name says, special characters are used for various special purposes, for instance the % sign you mentioned is used to mark environment variables. You can try it yourself to see how it works:
    • Type %userprofile% on File Explorer addessbar, hit Enter to open your user folder
    • Type %windir% on File Explorer addessbar, hit Enter to open Windows folder
    • Type %localappdata% on File Explorer addessbar, hit Enter to open Users\Your_Username\Appdata\Local folder
    • Type %appdata% on File Explorer addessbar, hit Enter to open Users\Your_Username\Appdata\Roaming folder
    To search files and folders containing these special characters use filename:*X (filename followed by : and * plus the character you are searching) replacing X with actual character. For instance to find all files and folders with % sign in name, search for filename:*%.

    To find all files and folders with string &Test in file / folder name search for filename:*&Test.
     
Thema:

File Explorer search does not correctly handle ~ character in filenames

Loading...
  1. File Explorer search does not correctly handle ~ character in filenames - Similar Threads - File Explorer search

  2. File Explorer search does not correctly handle ~ character in filenames

    in Windows 10 Network and Sharing
    File Explorer search does not correctly handle ~ character in filenames: Please fix the behavior of File Explorer search when using the tilde ~ character. This character is valid in filenames, but searching for ~ e.g., using *~* returns unrelated results or behaves inconsistently. This causes confusion and makes it hard to find files with ~ in...
  3. File Explorer search does not correctly handle ~ character in filenames

    in Windows 10 Gaming
    File Explorer search does not correctly handle ~ character in filenames: Please fix the behavior of File Explorer search when using the tilde ~ character. This character is valid in filenames, but searching for ~ e.g., using *~* returns unrelated results or behaves inconsistently. This causes confusion and makes it hard to find files with ~ in...
  4. File Explorer, Filename:, Search

    in Windows 10 Gaming
    File Explorer, Filename:, Search: On my OneDrive for Business folder, I use "Ctrl + E" to search for a file using the "filename:" function, making it easy to access. It does not allow me to retrieve it in search results for certain files. I tried to rename the file, but it did not appear in the search...
  5. File Explorer, Filename:, Search

    in Windows 10 Software and Apps
    File Explorer, Filename:, Search: On my OneDrive for Business folder, I use "Ctrl + E" to search for a file using the "filename:" function, making it easy to access. It does not allow me to retrieve it in search results for certain files. I tried to rename the file, but it did not appear in the search...
  6. Inaccurate search for filenames in File Explorer

    in Windows 10 Network and Sharing
    Inaccurate search for filenames in File Explorer: I use ~<22 in File Explorer to search for images with filenames starting with '22' the year they were taken. Some images whose file names do not start with '22' are included in the result. They are of File Type 'Adobe Photoshop Image.22'Is there a way to prevent these...
  7. Inaccurate search for filenames in File Explorer

    in Windows 10 Gaming
    Inaccurate search for filenames in File Explorer: I use ~<22 in File Explorer to search for images with filenames starting with '22' the year they were taken. Some images whose file names do not start with '22' are included in the result. They are of File Type 'Adobe Photoshop Image.22'Is there a way to prevent these...
  8. Inaccurate search for filenames in File Explorer

    in Windows 10 Software and Apps
    Inaccurate search for filenames in File Explorer: I use ~<22 in File Explorer to search for images with filenames starting with '22' the year they were taken. Some images whose file names do not start with '22' are included in the result. They are of File Type 'Adobe Photoshop Image.22'Is there a way to prevent these...
  9. List filenames that don't contain a specific character, File Explorer Search queries.

    in Windows 10 Network and Sharing
    List filenames that don't contain a specific character, File Explorer Search queries.: TagSpace adds string names inside of brackets that are used as tags. Eg: report[jane pending].pdf. "jane" and “pending” are used as tags to find the file report.pdf. When using Win10 File Explorer to list the files in the folder containing report[jane pending].pdf, is there a...
  10. Sorting Files within File Explorer by the last character in the filename

    in Windows 10 Network and Sharing
    Sorting Files within File Explorer by the last character in the filename: Is there a way to Sort Files within File Explorer by the last character in the filename. See below. Show all the "A"'s first and others last. File0001 File0001A File0002 File0002A File0003 File0001A...