---
title: "Discussion on \"async vs defer in JavaScript: How Script Loading Really Works\" | Hashnode"
description: "Discussion on \"async vs defer in JavaScript: How Script Loading Really Works\". How Script Loading Really Works\nIf you’ve ever added JavaScript to an HTML page, you’ve probably written something like this:\n<script src=\"script.js\"></script>\n\nBut modern JavaScript gives you two powerful attributes:\n\nasync\n\ndefer\n\n\nThey change how ..."
url: "https://hashnode.com/posts/async-vs-defer-in-javascript-how-script-loading-really-works/693f8d1af9a8c45810747a29"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [async vs defer in JavaScript: How Script Loading Really Works](https://javascript-beginner-articles.hashnode.dev/async-vs-defer-in-javascript-how-script-loading-really-works?utm_source=hashnode&utm_medium=feed)

How Script Loading Really Works If you’ve ever added JavaScript to an HTML page, you’ve probably written something like this: <script src="script.js"></script> But modern JavaScript gives you two powerful attributes: async defer They change how ...

Dec 15, 2025 · 4 min read · javascript-beginner-articles.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#js](https://hashnode.com/tag/js)
-   [#beginners](https://hashnode.com/tag/beginners)
-   [#asynchronous-javascript](https://hashnode.com/tag/asynchronous-javascript)
-   [#deferred-execution](https://hashnode.com/tag/deferred-execution)
-   [#defer](https://hashnode.com/tag/defer)

## Written by

[Madankumar](https://hashnode.com/@madankumar-sajjanar)

@madankumar-sajjanar · Bangaluru,Karnataka,India

  
[View profile](https://hashnode.com/@madankumar-sajjanar)

Keep Coding

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
