liveBook · Manning

Wwwroot folder

The wwwroot folder is the conventional ASP.NET Core web-root directory from which static web content is served.

How 2 Manning books explain it

ASP.NET Core in Action, 3e

The wwwroot folder is the conventional ASP.NET Core application directory whose files are publicly served as static content.

How it is used
Provides the public static-file boundary for ASP.NET Core applications, including Razor Pages applications.
How deep it goes
Explains folder behavior, middleware configuration, request outcomes, organization, and publishing, but not custom file-provider configuration.
Examples
Uses moon.jpg, missing.jpg, UseStaticFiles, and dotnet publish to demonstrate serving, failure, configuration, and deployment.
What you can do after
Build it from scratch by placing assets in wwwroot, enabling UseStaticFiles, testing URLs, and publishing the application.

Read how ASP.NET Core in Action, 3e explains wwwroot folder →

Pro ASP.NET Core 7, Tenth Edition

The wwwroot folder is the conventional ASP.NET Core project directory from which static web content is served.

How it is used
Stores static files that an ASP.NET Core application serves alongside dynamically generated content.
How deep it goes
Shows folder creation, static-file configuration, and browser verification, but defers fuller treatment of static-file serving.
Examples
Uses demo.html at /demo.html and a validation stylesheet stored at wwwroot/css/styles.css.
What you can do after
Operate/configure it by adding a static file, enabling serving when needed, and checking its browser URL.

Read how Pro ASP.NET Core 7, Tenth Edition explains wwwroot folder →

Related concepts

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.