OneDrive using all your local disk space from Sync
If you are running of space on your local hard drive in your computer due to the synchronized copies of files from OneDrive you can use Files On-Demand for Windows to reduce the amount of local disk space required.
In the lower right of your screen if you see your OneDrive icon click it to open then click the gear icon in the upper right and choose Settings.
Windows 10
Click – Save space and download files as you use them below Files On-Demand
Windows 11
OneDrive Settings, Sync and backup chosen on left
Scroll to the bottom, click the drop down for Advanced settings
Make sure Files On-Demand is On
Now in File Explorer when looking at OneDrive you will see either Blue cloud icon – these files and folders are available online, no local copy. Locally available files and folders have a green circle with check mark to show it is locally available, you can right click those and choose Free up space to clean up the local copies and leave only the copy in the cloud. File and folders with a solid green circle and a white check mark are set to always be kept on this device.
Some notes if the file is only on OneDrive (in the cloud) then if you do not have Internet access you cannot access the file. If a local copy exists it will allow you to work on the file and sync it back when you are connected to the Internet again.
For more information – https://support.microsoft.com/en-us/office/save-disk-space-with-onedrive-files-on-demand-for-windows-0e6860d3-d9f3-4971-b321-7092438fb38e