Recover deleted notebooks from the Trash

Deleted items can be recovered from the Trash for 30 days after deletion.

Written by vivian.wilfred

Last published at: September 2nd, 2022

Introduction

Deleted notebooks are moved to the user's Trash folder and stored there for 30 days. After 30 days have passed, the deleted notebooks are permanently removed and cannot be recovered. You can permanently delete the items in the Trash sooner by selecting Empty Trash.

If you accidentally delete a notebook it is not permanently deleted. It is just moved to the Trash. As long as you have not manually emptied the Trash, you can restore the notebook by moving it from the Trash folder to another folder.

Warning

Objects that are deleted via APIs or the Databricks CLI do not move to the Trash. They are permanently deleted. The Trash folder is a UI-only feature.

Recover deleted notebooks

  1. Log into Databricks.
  2. Select Workspace from the sidebar.
  3. Select Users.
  4. Select your user folder.
  5. Select Trash.
  6. Select the notebook you want to restore and drag it from the Trash folder to your user folder.

Info

A normal user can only recover items from their own Trash. Admin users can recover deleted items from any user's Trash folder.

Prevention

You can mitigate accidental deletions by backing up your notebooks frequently.

Options to backup notebooks include:

  1. Git integration with Databricks Repos (AWS | Azure | GCP)
  2. Azure DevOps Services version control (Azure)
  3. Bitbucket Cloud and Bitbucket Server version control (Azure)


Was this article helpful?