To load JavaScript file, just add the following line of code in index. html file . Run the server by using python manage.py runserver command. After that access the template by localhost:8000/index URL, and it will produce the following output to the browser.