You are here:
Manage Deleted Custom Objects
Deleted custom objects appear in the Deleted Objects list for 15 days. During this time, you can choose to permanently delete the object and its data, or you can undelete them. If you undelete a custom object, some manual cleanup can be required to restore list views and other customizations that use the object.
View Deleted Custom Objects
To view a list of deleted custom objects, go to object management settings for custom objects. The Deleted Objects link appears only when you have at least one deleted custom object in your org. The number in parentheses indicates the total number of deleted custom objects. In the Deleted Objects list, you can:
- Click the object’s label to view details about it.
- Click Erase to permanently remove the object and its data.
- Click Undelete to restore the object and its data.
What Happens When You Hard Delete a Custom Object
A custom object can be hard deleted either manually or automatically after 15 days.
- The custom object’s definition and data are permanently deleted and can’t be restored.
- The custom object and its data no longer count against your org’s limits.
- If the deleted object is on the detail side of a master-detail
relationship, master records currently in the Recycle Bin aren’t
restorable if one or more detail records were automatically deleted as
a result of the master record being deleted. Attempting to undelete
the master record results in an error.Note This scenario only happens when the deleted detail records have their custom object definition hard deleted while the master record is in the Recycle Bin.
Limitations for Restoring Truncated Custom Objects
Copies of truncated custom objects also appear in the list of deleted objects. Truncated custom objects can’t be restored to their original state. Undeleted copies of truncated objects have a new name and new URL, and some fields and data can’t be manually restored.
Restoring a Custom Object to Its Predeleted State
When you restore a deleted custom object, its records are also undeleted, including any that were in the Recycle Bin. It can take several hours before you can search an undeleted object’s records.
To ensure that you return the object to its fully functional, predeleted state, check all affected conditions and customizations, and manually fix them if necessary.
- AppExchange packages
- Add the custom object to any appropriate AppExchange packages.
- Custom tabs
- Re-create a custom tab for the object and add it to any custom apps that use it.
- List views, reports, and workflow rules
- Re-create them.
- Validation rules and approval processes
- Reactivate them.
- Formula fields
- Open and save any custom formula fields on the object to re-enable them.
- Page layouts
- Page layouts are restored automatically on the undeleted object. Page layouts are also restored automatically on other objects that use the page layout in a related list—as long as the page layout wasn’t edited while the object was deleted. Otherwise, you must add the related list back to the other object.
- Custom report types
- For custom report types where the deleted object wasn’t the main object, add the reference back to the restored object. Reports based on the custom report type are automatically restored if they weren’t edited while the object was deleted. Re-create any reports that were edited.
- Relationships
- If the deleted custom object was on the detail side of a master-detail relationship, Salesforce converted it to a lookup relationship. Change the relationship back to master-detail.
- Developer name
- The developer name for the object was changed to objectname_del. Change it back to the original name, objectname_c,so that customizations using the name work properly.
- Deployment status
- When the custom object was deleted, its Deployment Status field was set to In Development. After you restore all affected customizations to the undeleted object, change its status back to Deployed.

