simpleserver-tool 0.3.0

.NET 6.0
dotnet tool install --global simpleserver-tool --version 0.3.0
This package contains a .NET tool you can call from the shell/command line.
dotnet new tool-manifest # if you are setting up this repo
dotnet tool install --local simpleserver-tool --version 0.3.0
This package contains a .NET tool you can call from the shell/command line.
#tool dotnet:?package=simpleserver-tool&version=0.3.0
nuke :add-package simpleserver-tool --version 0.3.0


NuGet version (simpleserver-tool) Build app codecov

A simple server command line tool to run a static backend. Written in C#, cross platform.

It is cross platform, has around 30MB, and does not require .NET ou .NET Framework to run.


Download the version to your OS (see bellow) and run it like this:

simpleserver [<path>] [options]

If you run it without arguments it will serve the current running directory (pwd/cwd), bound to all network interfaces ( on port 8080 and without logging to stdout. These are all configurable and there are many other options.

option type default value description
-i, --index switch Use a default index file when a file is not found.
--interface <interface> string Network interface (IP or hostname) to bind the server to.
-p, --port <port> u16 8080 Port to run the server at.
--index-name <index-name> string index.html Default index file name.
-v, --verbose switch Show verbose output.
-s, --simple-paths switch Use simple paths. Allows to serve 'file.html' as '/file'.
-l, --log-http switch Log http output to stdout.
-d, --directory-browsing switch Enable directory browsing.

You can see this options in the command line by typing simpleserver --help.

For example, to run an SPA, you would want to serve every static file and serve index.html for every requested route that was not matched to a file. Like this:

simpleserver -i

To change the file, you'd also supply another option:

simpleserver -i --index-name default.html

Incompatible options

You can't run directory browsing and index file at the same time. If you try, directory browsing will be disabled.

You can't run simple paths and directory browsing at the same time. If you try, simple paths will be disabled.

Running the framework dependent .dll

The framework dependent simpleserver.dll can be run where you already have the .NET Runtime installed. You'll need the .NET 6 runtime, and run it like this:

dotnet simpleserver.dll [<path>] [options]

You will need all the files that are in the .tgz, decompress it to a directory and run it from there.


Standalone binaries

Download an artifact from the latest release and add it to your path.

There are artifacts for Windows and Linux (x86, ARM and Musl). The Linux ones are are dynamic binaries, they can't run on distroless containers (FROM scratch).

  • simpleserver-linux-arm - Linux ARM
  • simpleserver-linux-musl-x64 - Linux x64 Musl (Alpine etc)
  • simpleserver-linux-x64 - Linux ARM
  • simpleserver.exe - Windows x64
  • simpleserver.tgz - Cross platform, framework dependent

The .pdb files are symbol files and are only needed for debugging, not running the application.

As a dotnet cli tool

This tool can be installed as a dotnet global tool, if you have the .NET Sdk installed. It is hosted on as simpleserver-tool. Install with:

dotnet tool install --global simpleserver-tool


This is written with dotnet-suggest. You'll need the .NET Sdk to enable completions. The detailed steps are outlined at the command-line-api project.

It works everywhere the .NET Sdk works. The supported shells are detailed on the above document and include Bash, Zsh and PowerShell.


Questions, comments, bug reports, and pull requests are all welcome. Submit them at the project on GitHub.

Bug reports that include steps-to-reproduce (including code) are the best. Even better, make them in the form of pull requests.


Giovanni Bassi.


Licensed under the MIT License.

Product Versions
.NET net6.0 net6.0-android net6.0-ios net6.0-maccatalyst net6.0-macos net6.0-tvos net6.0-windows net7.0 net7.0-android net7.0-ios net7.0-maccatalyst net7.0-macos net7.0-tvos net7.0-windows
Compatible target framework(s)
Additional computed target framework(s)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

Version Downloads Last updated
0.3.0 303 2/20/2022
0.1.22 286 2/19/2022
0.1.0 292 2/19/2022