Excluding Folders from FSLogix with redirections.xml: A Practical Guide

redirections.xml keeps chosen folders out of FSLogix profile containers. Where the file goes, the exact XML format and what each Copy value does, the Teams cache folders Microsoft says are safe to exclude, how to confirm exclusions are working, and why less is more.

By David,

FSLogix exclusions are set in a file called redirections.xml, which tells FSLogix to keep chosen folders out of the user's profile container by redirecting them to the local disk. You create the file yourself, put it in a folder that RedirXMLSourceFolder points to, and FSLogix copies it into each user's container at sign-in. Each Exclude entry names a folder relative to the user profile, and its Copy attribute says whether any data moves between the container and the local copy. Microsoft's guidance is to exclude as little as possible: only data you know is safe to lose, such as caches.

The short version: Point RedirXMLSourceFolder at a share folder (not the file) that users can read. Start from the cache folders Microsoft lists for new Teams in VDI, use Copy="0", and add almost nothing else. Check the profile log for "Redirections.xml copy success" after the next sign-in. Remember that exclusions only take effect at the next sign-in, don't shrink existing containers, and do nothing for Office (ODFC) containers.

This guide goes with our FSLogix troubleshooting guide and profile size guide. Everything below is from Microsoft Learn as of November 2026, with each source linked.


How redirections.xml works

  • FSLogix doesn't create the file. You write it and store it in a source folder, usually on a file share (redirections.xml).
  • RedirXMLSourceFolder (REG_SZ, under HKLM\SOFTWARE\FSLogix\Profiles) points at that folder. "Don't add the file name to the path. This setting is a folder path only." Users need read access to it (configuration settings, tutorial).
  • At sign-in, if the file in the source folder is different from the one in the container, FSLogix copies it to %userprofile%\AppData\Local\FSLogix\redirections.xml in the container. Changes take effect only after the user signs out and back in.
  • Excluded folders live on the local disk under C:\Users\local_<username> and are linked into the profile, so applications still find them where they expect.
  • It applies to profile containers only. It "has no effect when using ODFC containers."
  • Removing the source file doesn't undo it. Deleting or renaming the file at the source leaves the copy in every user's container. To undo exclusions, empty the file's contents at the source instead. Since FSLogix 25.02, removing the RedirXMLSourceFolder setting removes the file from the container at the next sign-in (release notes).

The redirections.xml format

This is Microsoft's own example, which it labels "should not be used in any production environment" (redirections.xml):

<?xml version="1.0" encoding="UTF-8"?>
<FrxProfileFolderRedirection ExcludeCommonFolders="49">
<Excludes>
<Exclude Copy="3">AppData\Roaming\Contoso\ContosoSalesApp</Exclude>
<Exclude Copy="0">AppData\Local\Contoso\ContosoWebApp</Exclude>
</Excludes>
<Includes>
<Include>AppData\Local\Contoso\ContosoWebApp\Settings</Include>
</Includes>
</FrxProfileFolderRedirection>

Paths are relative to the user profile. Write AppData\Local\..., never C:\Users\%username%\AppData\Local\....

The Copy attribute decides what moves between the container and the local folder. Leaving it out is the same as 0:

CopyWhat happensUse it
0An empty local folder; nothing is copied. New data is discarded at sign-outAlmost always. Microsoft calls it "the most common value"
1Copies from the container to the local folder at sign-in; new data is lost at sign-outRarely
2Copies from the local folder to the container at sign-out"Don't use this value unless directed by a Microsoft support engineer"
3Both directionsRarely; it defeats the purpose for large folders

Includes keep a subfolder of an excluded folder in the container. If a folder is in both lists, the exclude wins. An included folder's parent must already exist in the container.

ExcludeCommonFolders is a bitmask for whole known folders: 1 Contacts, 2 Desktop, 4 Documents, 8 Downloads, 16 Links, 32 Music, 64 Pictures and Videos, 128 low-integrity folders such as AppData\LocalLow. Add the numbers together; Microsoft's example uses 49 (Contacts, Links and Music). Excluding Desktop or Documents throws that data away at sign-out, so use OneDrive Known Folder Move for those instead.


What to exclude on Azure Virtual Desktop

Microsoft doesn't publish a recommended exclusion list for FSLogix. Its FAQ says "FSLogix doesn't provide recommended values" and "don't exclude user profile data for applications unless the application owner has documented the data can be excluded." There's no technical limit on entries, but "less is more": every file system request is checked against the list (FAQ).

The application owner that does document it is Teams. For new Teams in VDI, Microsoft lists these folders under AppData\Local\Packages\MSTeams_8wekyb3d8bbwe\LocalCache\Microsoft\MSTeams\ as safe to exclude: Logs, PerfLog, EBWebView\WV2Profile_tfw\WebStorage and EBWebView\WV2Profile_tfw\GPUCache. It adds StartMenuExperienceHost and (on Windows Server 2019) ShellExperienceHost TempState folders, and says: "Other than the folders in this section, we don't recommend excluding additional directories" (new Teams VDI).

A starting file based on Microsoft's FSLogix tutorial and the Teams list:

<?xml version="1.0" encoding="UTF-8"?>
<FrxProfileFolderRedirection ExcludeCommonFolders="0">
<Excludes>
<Exclude Copy="0">AppData\Local\Packages\MSTeams_8wekyb3d8bbwe\LocalCache\Microsoft\MSTeams\Logs</Exclude>
<Exclude Copy="0">AppData\Local\Packages\MSTeams_8wekyb3d8bbwe\LocalCache\Microsoft\MSTeams\PerfLogs</Exclude>
<Exclude Copy="0">AppData\Local\Packages\MSTeams_8wekyb3d8bbwe\LocalCache\Microsoft\MSTeams\EBWebView\WV2Profile_tfw\WebStorage</Exclude>
<Exclude Copy="0">AppData\Local\Packages\MSTeams_8wekyb3d8bbwe\LocalCache\Microsoft\MSTeams\EBWebView\WV2Profile_tfw\GPUCache</Exclude>
</Excludes>
</FrxProfileFolderRedirection>

One discrepancy to know about: the Teams page names the folder PerfLog and the FSLogix tutorial names it PerfLogs. Check which exists in your Teams version and use that (tutorial).

What not to exclude. Microsoft's guidance is that "data in the user's profile isn't designed to be removed or excluded." Stateless data like browser caches is the one category it calls appropriate. Anything that holds settings, sign-in state or work will be lost at every sign-out.

What FSLogix already excludes. You don't need entries for credential and protection folders (AppData\Roaming\Microsoft\Protect, Credentials) or Office's file cache; FSLogix always redirects those, and it deletes several identity and MSIX app cache paths at sign-out (container types).


How to check exclusions are working

After the user signs out and back in, open the profile log (C:\ProgramData\FSLogix\Logs\Profile\). After "Begin Session: StartShell", look for "Redirections.xml copy success", one "Adding exclude rule for folder" line per entry, and "Added redirection" lines showing each folder going to C:\Users\local_<username>\... (tutorial). In the session, frx list-redirects (from C:\Program Files\FSLogix\Apps) lists the active redirections (frx).

If none of that appears, Microsoft's FAQ lists three usual causes: RedirXMLSourceFolder includes the file name, users can't read the folder, or the path can't be found (FAQ). Our FSLogix logs reference covers the rest of the log.


Exclusions won't shrink existing containers

Adding an exclusion stops new data landing in the container, but anything already there stays. "FSLogix doesn't have tools or features to remove this data" (container size troubleshooting). To reclaim the space, remove the old data while the user is signed out and let compaction recover it, as described in FSLogix profile size and compaction.


Other ways to keep data out of the profile

  • OneDrive Known Folder Move keeps Desktop, Documents and Pictures in OneDrive instead of the container (Known Folder Move). OneDrive doesn't support the same container being used by multiple sessions at once (OneDrive VDI support).
  • Include and exclude groups. FSLogix creates four local groups, an include and an exclude group for each container type, to decide which users get a container at all. The exclude groups are empty and the include groups contain Everyone by default (include and exclude groups). That's for excluding people, not folders.
  • The Office container (ODFC). It puts Office data in a second container. Microsoft says there's "no need or benefit" to it when profile containers are your primary solution, but it can be useful to size Office data separately (ODFC, container types). Remember that redirections.xml doesn't apply to it.

How Atlas AVD helps

In Atlas AVD, Workspace → FSLogix → Profiles → Scan sizes & orphans reads every container's size in a host pool and flags the outliers well above the fleet median, which shows whether your exclusions are working and which users to look at first. The FSLogix optimization page covers the rest.


FAQ

Where does redirections.xml go?

In a folder you choose, usually on a file share users can read. Set RedirXMLSourceFolder to that folder path (not the file name), and FSLogix copies the file into each user's container at sign-in.

What does Copy="0" mean in redirections.xml?

The folder is redirected to an empty local folder and nothing is copied in or out, so its contents are thrown away at sign-out. It's the value Microsoft says is most common.

What should I exclude from FSLogix for Teams?

The new Teams cache folders Microsoft lists for VDI: Logs, PerfLog, and the WebView2 WebStorage and GPUCache folders under the MSTeams package's LocalCache. Microsoft recommends not excluding anything else for Teams.

Why aren't my FSLogix exclusions working?

Usually because RedirXMLSourceFolder includes the file name, users can't read the folder, or the path is wrong. Exclusions also only apply after the user signs out and back in, and never to Office containers.

Do FSLogix exclusions reduce the size of existing containers?

No. They stop new data being stored. Data already in the container stays until you remove it and compaction reclaims the space.

FSLogix behavior and settings are from Microsoft Learn as of November 2026: redirections.xml, the redirections.xml tutorial, configuration settings, container types, include and exclude groups, ODFC, the FAQ, the release notes and frx. Teams folders are from new Teams VDI requirements.