Convert 18 Character Id to 15 Character in Salesforce Apex Biswajeet December 5, 2013 No Comments on Convert 18 Character Id to 15 Character in Salesforce Apex String accountId = String.valueOf(acc.Id).substring(0, 15);