Overview – Salesforce lightning uses different domain name compare to Salesforce classic. Create and deploy a unique domain name while activating Lightning experience.
Impact – If your org has hard coded Salesforce instance URLs in Buttons, Apex classes, Visualforce pages and Tabs. Update it with new lightning experience domain URL. If you continue using the same, it will redirect Users to salesforce classic.
Solution – To replace old classic URLs with new Lightning URLs. You may use global methods to get current instance using.
For formula editors – “LEFT($Api.Partner_Server_URL_260, FIND( '/services', $Api.Partner_Server_URL_260))”
For Apex classes – “URL.getSalesforceBaseUrl()”
Example –
Existing hardcoded URL- cs54.salesforce.com/00O50000003QjC6
New URL – URL.getSalesforceBaseUrl() + ‘/00O50000003QjC6’
OR
LEFT($Api.Partner_Server_URL_260, FIND
( '/services', $Api.Partner_Server_URL_260)) + ‘/00O50000003QjC6’