> For the complete documentation index, see [llms.txt](https://docs.umbraco.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.umbraco.com/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/managing-views-and-assets.md).

# Managing Views and Assets

How to manage templates, partial views, stylesheets, and JavaScript files, and what to consider when editing them in the backoffice.

Templates, partial views, stylesheets, and JavaScript files are all files in your Umbraco project. Templates and partial views are Razor views, and stylesheets and JavaScript files are static assets.

You can create and edit these files in the backoffice, which works well for quick changes during local development. For ongoing work, maintain them in an IDE and keep them in source control with the rest of your code. For more information, see [Source Control](/umbraco-cms/17.latest/develop-with-umbraco/application-code/backend-and-custom-logic/source-control.md).

## Editing in the Backoffice

The backoffice works well for:

* Generating a template alongside a new Document Type. For more information, see [Working with Templates](/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/templates.md).
* Creating a partial view from one of the built-in snippets. For more information, see [Partial Views](/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/design/partial-views.md).
* Making quick changes during local development.

For ongoing work, use an IDE. Keep the following limitations in mind:

* The backoffice editors are plain text editors. They don't offer the tooling an IDE gives you, such as IntelliSense, linting, or formatting.
* Depending on how you deploy, edits made in the backoffice of a deployed site might not move to your other environments. The next deployment can also overwrite them.

### Templates and Partial Views

Templates and partial views contain C# code, but the backoffice editor doesn't warn you about errors in it. Nothing flags a mistyped property name or a missing `using` directive before you save. Mistakes only surface when the page renders.

The runtime mode of your site also affects backoffice editing:

* In `Production` runtime mode, creating, editing, renaming, and deleting templates and partial views in the backoffice is blocked entirely. For more information, see [Runtime Modes](/umbraco-cms/17.latest/run-in-production/runtime-modes.md).
* Outside `Production`, backoffice changes take effect immediately only in `BackofficeDevelopment` mode (the default) with the `Umbraco.Cms.DevelopmentMode.Backoffice` package installed. Otherwise, you must rebuild and restart the site. For details, see ["InMemoryAuto models builder and Razor runtime compilation have moved into their own package"](https://github.com/umbraco/UmbracoDocs/tree/main/17/umbraco-cms/get-started/upgrading-and-migrating/version-specific/README.md#umbraco-17) in the Version-specific upgrades guide.

## Where the Files Live

| File type        | Default location  |
| ---------------- | ----------------- |
| Templates        | `Views`           |
| Partial views    | `Views/Partials`  |
| Stylesheets      | `wwwroot/css`     |
| JavaScript files | `wwwroot/scripts` |

Your site can serve stylesheets and JavaScript from anywhere under `wwwroot`, so these files don't have to sit in the default folders. The backoffice only lists the folders set by the `UmbracoCssPath` and `UmbracoScriptsPath` settings. For more information, see [Global Settings](/umbraco-cms/17.latest/develop-with-umbraco/configuration/globalsettings.md).

## Adding Files Outside the Backoffice

Stylesheets and JavaScript files in the folders set by `UmbracoCssPath` and `UmbracoScriptsPath` appear in the backoffice, even when you add or edit them elsewhere. Click **...** next to the **Stylesheets** or **Scripts** folder and select **Reload children** to see the changes.

Templates work differently. Templates are registered in the Umbraco database, so a `.cshtml` file you add to the `Views` folder doesn't appear in the backoffice on its own. Create a template in the backoffice with an alias that matches the file name without the `.cshtml` extension. For example, a template with the alias `homePage` uses the `Views/homePage.cshtml` file. Umbraco keeps your existing file content instead of overwriting it. For more information, see [Working with Templates](/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/templates.md).

## Related Articles

* [Working with Templates](/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/templates.md)
* [Partial Views](/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/design/partial-views.md)
* [Stylesheets and JavaScript](/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/design/stylesheets-javascript.md)


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.umbraco.com/umbraco-cms/17.latest/develop-with-umbraco/templating-and-rendering/managing-views-and-assets.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
