Why a normal filename search fails
Download names are often poor clues. A useful report may be called download.pdf. A release archive may use a version number you no longer remember. A client portal may replace the original name with an ID.
The source website can be a better clue because it describes the context. You may not remember the report’s title, but you probably remember that it came from your bank or a government site.
Try a Spotlight metadata query
Open Terminal and search the Downloads folder with this pattern:
mdfind -onlyin ~/Downloads 'kMDItemWhereFroms == "*example.com*"c'
Change example.com to the website you remember. The asterisks allow other text before and after the domain. The final c makes the match case-insensitive.
To search another folder, replace ~/Downloads with its path. Dragging a folder from Finder into Terminal is the easiest way to insert a path with the right spelling.
Narrow the results with the clues you have
A source match may return many files. Use a smaller folder first, then look at file type and date. If the site has several subdomains, begin with the main domain. A search for github.com is broader and more reliable than guessing a long release URL.
You can inspect any result with Finder Get Info or:
mdls -name kMDItemWhereFroms -name kMDItemFSName "/path/to/result"
This lets you confirm that the domain appears in the saved metadata rather than somewhere else in the file.
Use a visual source browser for repeated searches
Download Detective scans a folder you choose and lists source domains in a sidebar. Click a domain to see only its files. You can then type part of a name, extension, path, domain, or full URL. Filters cover common groups such as documents, images, archives, video, audio, and applications.
This is useful when you do not know which domains are present. Instead of writing one query at a time, you can browse the saved sources and their file counts. Select a file to see all known URLs, preview it with Quick Look, reveal it in Finder, or return to the source page.
The app does not read file contents for scanning or upload a list of your files. It uses the local metadata already on your Mac and does not modify the folder.
What “Unknown Source” means
Not every result will have a website. Download Detective calls these files Unknown Source. In a Terminal query, they simply do not match a domain.
Common reasons include locally created files, downloads made by tools that do not write source URLs, and transfers that remove Mac metadata. An unknown source is not an error, and it says nothing certain about whether a file is safe.
Do not search private URLs on the web
Saved source URLs can contain account paths, document IDs, or temporary query parameters. Keep them private. A local metadata search is different from pasting the full URL into a search engine or public support post.
If you open an old source URL, inspect the domain first. Pages move, domains change hands, and temporary links expire. Download Detective only hands the URL to your default browser when you explicitly choose Open Source URL.
A practical search order
- Choose the smallest likely folder.
- Search the main domain, not a guessed full URL.
- Filter by broad file type.
- Sort by date or name.
- Use Quick Look or Finder to confirm the file.
- Inspect the full source URL only when needed.
This source-first method is often faster than opening dozens of files. It also works after a file has been renamed, as long as its source metadata survived.