Tun's Random Thoughts
BlogProfilePhoto Gallery
All Projects
NakedExplorer

In Progress

NakedExplorer

View on GitHub
Tech Stack
C

NakedExplorer

A single-file, dependency-free Windows file manager that hosts the real Windows Explorer view.

Written in plain C against the Win32 API and the IExplorerBrowser shell interface.

License: MPL-2.0 Language: C Platform: Windows MSVC MinGW--w64

Features · Building · Usage · Architecture · Limitations

NakedExplorer is a minimalist file manager for Windows built around one idea: instead of re-implementing a file list with custom controls, it embeds the same browser view Windows Explorer itself uses via the IExplorerBrowser COM interface. The entire application is a single C source file that compiles to one portable executable with no installer and no third-party dependencies.

The project targets minimal Windows environments — such as Windows Server Core and Hyper-V Server — where the full Explorer shell (explorer.exe) is not running, and demonstrates how much of the native Explorer experience can be reused from plain Win32 code.

Features

Area What is included
Native Explorer view Hosts the actual Windows Explorer browser view (IExplorerBrowser) in details mode — native icons, columns, sorting, selection, keyboard navigation, and shell-provided context menus come from Windows itself.
Navigation Address bar with direct path entry (press Enter or click Go), and an Up button for the parent directory.
Address sync Address bar and window title automatically track the current folder via IExplorerBrowserEvents navigation callbacks.
Path handling Accepts any path the shell can parse (SHParseDisplayName), with a clear error dialog for invalid locations.
Portability One source file, one executable, no installation, no registry writes, no external dependencies beyond system DLLs.
Unicode Full Unicode build (UNICODE/_UNICODE), wide-character APIs throughout.

Technology stack

Layer Technology
Language C (C99), single translation unit (main.c)
Platform Win32 API, Unicode build
File browsing IExplorerBrowser COM interface (Explorer Browser, CLSID_ExplorerBrowser)
Shell integration SHParseDisplayName, SHGetPathFromIDList, PIDL-based navigation
UI Win32 windowing, Common Controls (comctl32), address-bar subclassing
Path utilities shlwapi (PathRemoveFileSpec), strsafe (StringCchCopy)
Build MSVC (cl) or MinGW-w64 (gcc), driven by build.ps1, build.bat, or the Makefile

Prerequisites

  • Windows Vista or newer (the IExplorerBrowser interface, implemented in ExplorerFrame.dll, was introduced in Vista)
  • Windows SDK headers and libraries (shobjidl.h, shlobj.h, shlwapi.h, strsafe.h)
  • One of:
  • Microsoft Visual C++ (tested with Visual Studio 2022), or
  • MinGW-w64 (gcc / x86_64-w64-mingw32-gcc)

Building

PowerShell (MSVC or MinGW, auto-detected)

.\build.ps1

Command Prompt (Visual Studio 2022 environment, MinGW fallback)

build.bat

MinGW-w64 with the Makefile

On Windows or cross-compiling from Linux:

make

or manually:

x86_64-w64-mingw32-gcc -O2 -mwindows -o SimpleFileBrowser.exe main.c -lcomctl32 -lshell32 -luser32 -lgdi32 -lkernel32 -ladvapi32 -lole32 -lshlwapi

MSVC directly

From a Visual Studio Developer Command Prompt:

cl /O2 /W4 /Fe:SimpleFileBrowser.exe main.c /link user32.lib gdi32.lib kernel32.lib shell32.lib comctl32.lib advapi32.lib ole32.lib shlwapi.lib

Usage

Copy SimpleFileBrowser.exe to the target machine and run it — no installation required:

SimpleFileBrowser.exe

The application starts in the current working directory. Type a path in the address bar and press Enter, use Up to move to the parent folder, and interact with the file list exactly as you would in Windows Explorer.

Architecture

The IExplorerBrowser approach

Classic minimal file browsers re-implement everything with a ListView control: manual directory enumeration (FindFirstFile/FindNextFile), manual icon lookup (SHGetFileInfo), and manual sorting and context menus. NakedExplorer takes the opposite route.

At startup it calls CoCreateInstance(CLSID_ExplorerBrowser) to create the same Explorer Browser object that powers the folder view in Windows Explorer itself, initializes it into the client area of a plain Win32 window with details-view folder settings (FVM_DETAILS), and lets the shell do the rest:

  • Rendering, icons, columns, sorting, and context menus are provided by the hosted shell view — no custom drawing or list management code.
  • Navigation is PIDL-based: typed paths are resolved with SHParseDisplayName and passed to BrowseToIDList, so any shell-parseable location works.
  • State sync flows through a small IExplorerBrowserEvents COM implementation (hand-rolled vtable, reference counting with InterlockedIncrement/InterlockedDecrement). On every completed navigation the address bar and window title are updated from the new PIDL via SHGetPathFromIDList.
  • Chrome is minimal by design: a subclassed edit control (Enter key), two buttons, and a resize handler that keeps the hosted view fitted to the window with IExplorerBrowser::SetRect.

The only COM lifecycle work is standard: CoInitialize at startup, Advise/Unadvise for events, and Destroy + Release on shutdown.

Why this matters for minimal Windows installations

On systems where explorer.exe is not running — Server Core, Hyper-V Server, recovery environments, kiosk setups — the underlying shell COM components (ExplorerFrame.dll, shell32.dll, comctl32.dll) are still part of the OS image in most editions. By hosting the Explorer Browser object directly, NakedExplorer delivers a near-complete Explorer experience without the shell process, in a single portable executable.

Limitations

  • Requires the Explorer Browser component (ExplorerFrame.dll). On images where the shell stack has been stripped entirely (for example, Nano Server), the application will fail to create the browser object.
  • Deliberately minimal chrome: no menu bar, no toolbar, no tabs, no bookmarks.
  • Navigation UI is path-string oriented; shell namespace locations that have no filesystem path display an empty address.

License

NakedExplorer is licensed under the Mozilla Public License 2.0. Modifications to MPL-covered files must remain available under the MPL when distributed.

© 2026 Tun's Random Thoughts. All rights reserved.