Website Building » Elementor » Can I add JavaScript to Elementor?

Can I add JavaScript to Elementor?

Last updated on December 22, 2022 @ 7:47 am

Adding JavaScript to Elementor is easy. Just follow these simple steps.

First, search for the “HTML” widget in the Elementor editor on the left.

Then drag the widget to the space where you want to place it.

PRO TIP: Adding JavaScript to Elementor can be risky and may lead to unexpected results. Make sure you know what you are doing before adding any code.

Now, input a JavaScript code in the settings on the left menu.

NOTE: For this example, we will use the code below just to test its functionality. The code should display the text written in bold.

<!DOCTYPE html>
<div id=”show”>

document.getElementById(“show”).innerHTML = “Text shown is written with JavaScript code.”;


And there you have it! You can now add JavaScript in Elementor.

Once done, just click on the “Update” button below to save your changes.


Kathy McFarland

Kathy McFarland

Devops woman in trade, tech explorer and problem navigator.