SharePoint Online files are usually available to sync to a folder on your computer. In some cases, you may want to prevent users from using a sync client with a site or library.
On the site, click Settings > Site Settings.
Under Search, click Search and offline availability.
In the Offline Client Availability section, select No.
To allow users to sync files again, set the Offline Client Availability option to Yes.
Note: This setting applies to the previous OneDrive for Business sync client and not the newer sync client. If you're not sure which you are using, see Which OneDrive app?