# Create a Microsoft 365 Plan for OneDrive for Business

Create a Microsoft 365 plan for OneDrive for Business. The Microsoft 365 plan specifies which users and user groups are backed up, how long the data is retained, and which user and user groups are content indexed.

You will assign the Microsoft 365 plan to the users and user groups that you add to the OneDrive for Business app.

If some users and user groups have different backup requirements, you can create additional Office 365 plans for OneDrive for Business.

Important

Before you create a Microsoft 365 plan, review the supported Microsoft 365 Standard and Enterprise plan configurations. For more information, see Configure Microsoft 365 Standard and Enterprise plans.

## Create a New Plan

1. From the Command Center navigation pane, go to Manage > Plans.

   The Plans page appears.

2. In the upper-right area of the page, click Create plan, and then select Microsoft 365.

   The Create Microsoft 365 plan dialog box appears.

3. In the Plan name box, enter a name for the plan.

4. Under Retention settings, specify how long to retain the data:

   - To retain for an unlimited time, select Retain indefinitely.

   - To retain for a limited time, select Retain deleted items for, and then specify the amount of time.

5. Click Save.

## Exclude Specific Files or Folders from OneDrive Backups

You can use regular expressions or wildcards to back up files and folders by their names. For example, you can use a regular expression to back up all folders and files that contain "sales" in their names, such as "SalesQ3".

You can exclude specific files or folders from OneDrive backups by adding them in the Exclusions section of the Microsoft 365 plan. File or folder paths copied directly from the Failed Items list of a backup job might not work as-is. The exclusion path must be formatted correctly before adding it to the plan.

For example, if you want to exclude a specific file path, format it as follows:

Original path: `\OneDrive\UserFolder\Documents\TestFile.docx`

Formatted for exclusion: `*UserFolder\Documents\TestFile.docx`

### Using Wildcards for Exclusions

You can use wildcards to simplify your exclusion entries and cover files that follow similar naming patterns.

- Use `*` (asterisk) to match zero or more characters.

  For example:

  - `file*.txt` matches `file.txt`, `file1.txt`, or `fileABC.txt`.

  - It does not match `file1.txtABC` or `file1.pdf`.

- Use `?` (question mark) to match exactly one character.

  For example:

  - `file?.txt` matches `file1.txt` or `fileA.txt`.

  - It does not match `fileABC.txt`.

- Combine `*` and `?` for more flexible matching.

  For example:

  - `log_??_*.csv` matches `log_12_data.csv` and `log_AB_2025.csv`.

  - It does not match `log_12_data.log`.

- Match files in a specific folder path by including the path before the pattern.

  For example:

  - `*\My Drive\RegTest3\File1*` matches files such as `My Drive\RegTest3\File1.txt` and `My Drive\RegTest3\File1AC.pdf`.

  - It does not match files outside that folder, such as `My Drive\File1.txt`.

Important

1. When no path is specified (as in the first three examples), the exclusion applies to any file that matches the pattern, regardless of its folder location.
2. When a full or partial path is included, only files in that path are considered by the filter. Files with the same name in other folders are not excluded.

## What to Do Next

To include or exclude specific files and folders in your backup, edit the Microsoft 365 plan. From the plan page, in the OneDrive tile, click Edit. Create folder filters and file filters as per your backup requirements.

You can use regular expressions or wildcards to back up files and folders by their names. For example, you can use a regular expression to back up all folders and files that contain "sales" in their names, such as "SalesQ3".

×

Loading...