I am just trying to open a popup window by clicking on custom link in my page layout and it seems working in salesforce classic but not in Lightning view.

What i have found is few people suggested to do as mentioned in trialhead section but i am unable to find out any way for custom links.

Can anyone help me to display a popup on click of custom link in lightning experience or suggest me the way that how can i achieve this ?


1 Answer 1


OnClick JavaScript buttons pose security and regulatory issues. Lightning was built from the ground up to deliver the most secure experience possible with technologies such as LockerService. We want to ensure the continued integrity of this security model and as a result will not be supporting OnClick JavaScript buttons in Lightning. However to ease the transition Salesforce are constantly looking for declarative and programmatic alternatives to help make this transition from OnClick JavaScript buttons to Lightning Alternatives easier and easier.

This table maps use cases for JavaScript buttons to alternate—and in most cases, better—solutions in Lightning.:-

enter image description here

Also, On Trailblazer community we have a group called "Lightning Now!" where experts can assist in this process

Refer below links for more Information :-

  1. Idea -Onclick Javascript Buttons with Lightning Experience
  2. Lightning Alternatives to JavaScript Buttons

The trailhead Lightning Alternatives to JavaScript Buttons will give you some example and more detailed explanation. You can edit your question and include the Onclick JavaScript Link to get more help.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .