---
title: "Restore a File in OneDrive or SharePoint"
canonical: "https://tech.calpoly.edu/space/CPKB/2424918/Restore%20a%20File%20in%20OneDrive%20or%20SharePoint"
format: markdown
---
Learn how to restore a previous version of a file or a deleted file from the Recycle bin.  


<details>
<summary>Restore a previous file version</summary>

In OneDrive and SharePoint, you can view and restore older versions of all your files. Version history works with all file types.  

1. Log in to [OneDrive ](https://calpoly.atlassian.net/wiki/spaces/CPKB/pages/732921887)or [SharePoint](https://calpoly.atlassian.net/wiki/spaces/CPKB/pages/732921887).
2. Select the document for which you want to restore an earlier version and click **Version History** from the toolbar.
3. Hover your mouse over the file you want to restore, click the **three vertical dots**, and click** Restore**.
  
4. The document version you selected becomes the current version. The former "current" version becomes the previous version in the Version History list.
</details>

<details>
<summary>Restore a deleted file from the Recycle bin</summary>

If you accidentally delete a file or folder, it may be recoverable from the Recycle Bin. Files in the recycle bin are automatically deleted after 93 days.

1. Log in to [OneDrive ](https://calpoly.atlassian.net/wiki/spaces/CPKB/pages/732921887)or [SharePoint](https://calpoly.atlassian.net/wiki/spaces/CPKB/pages/732921887).
2. In the left-hand menu, click on **Recycle bin**.
3. Select the file to be restored and click the** Restore** button on the toolbar.
</details>

---

## Related Articles

> Macro (contentbylabel)