How to Delete the Apex Triggers and Apex Classes from Production Salesforce Org?

Follow the below steps to delete the Apex Triggers and Apex Classes to Production Salesforce Org

Use IDE to create a new project and download all apex triggers/ apex classes from production salesforce org.

In the Apex Triggers ore Apex Classes you want to delete, open the metadata file for the respective Apex Class/Apex Trigger and change the status as “deleted”.

Save to server
Observe the status of the class in the example below:

<?xml version=”1.0″ encoding=”UTF-8″?>
<ApexClass xmlns=””>

1) You should try this technique in sandbox and become comfortable with it before attempting in production.
2) Double-check the class name before deleting.


Written by 

2x Salesforce MVP | Platform Champion | 18x Salesforce Certified | MuleSoft Certified | 8x Trailhead Ranger | TechForce Services | Sydney | Australia

Leave a Reply

Your email address will not be published. Required fields are marked *