<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn" -->

---
title: The Cost Of JavaScript - 2023 | daily.dev
description: As we build sites that are more heavily reliant on JavaScript, we sometimes pay for what we send down in ways that we can’t always easily see. In this talk,...
canonical: https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: The Cost Of JavaScript - 2023 | daily.dev
og:description: As we build sites that are more heavily reliant on JavaScript, we sometimes pay for what we send down in ways that we can’t always easily see. In this talk,...
og:url: https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn
og:image: https://api.daily.dev/og/posts/CcXhhg1Fn.png
og:image:alt: The Cost Of JavaScript - 2023
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# The Cost Of JavaScript - 2023

**[Community Picks](https://daily.dev/sources/community)** · 162 upvotes · 15 comments

## Summary

As we build sites that are more heavily reliant on JavaScript, we sometimes pay for what we send down in ways that we can’t always easily see. In this talk, Addy explains how and why JavaScript is the most expensive resource your site uses today—especially on mobile and lower-end desktops.

Web developers should focus on optimizing JavaScript bundles by keeping them small to improve download speeds, especially on mobile devices. Small JavaScript bundles improve network transfer speeds, lower memory usage, and reduce CPU costs.This can be achieved by splitting bundles larger than 50-100 kB. Additionally, it's crucial to enhance execution time by avoiding tasks that overly engage the main thread and by not using large inline scripts over 1 kB. Avoid creating Long Tasks that can keep the main UI thread busy and can push out how soon pages are interactive by users. These steps are vital as parse and compile costs have become faster than before.

He will also share tips for fixing JavaScript performance issues so everything loads quicker. A little discipline can help if you want your site to load and be interactive as soon as possible on mobile.

A few things that will be covered:
- What the dominant costs of heavy JavaScript are
- How median hardware plus heavy JavaScript can impact user-experience
- Tips and tricks for reducing the cost of JavaScript, reducing long-tasks and improving the Core Web Vitals metrics
- Things frameworks and browsers are doing to try reducing the cost of JavaScript by default.
- How new performance metrics can help you reason about where to optimize JavaScript to improve user interactions

Target Audience: Intermediate web developers

Originally presented at Web Unleashed

#javascript #webdevelopers #programming #webperformance

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://www.youtube.com/watch?v=ZKH3DLT4BKw>

## Community discussion

Top comments from developers on daily.dev.

**@ashuzon** · 19 upvotes

> Can we just get articles?

**@hamlet** · 10 upvotes

> While it's not an article, it's nice to get something like a video or podcast but it would be nice to have a tag so people know when clicking.

**@trivenge** · 6 upvotes

> I agree, videos and podcasts, well, any link, should have a snippet of text indicating what it actually is, as some people just want to read.

**@anjapcodes** · 2 upvotes

> Hi, I've just opened this feature request on thumbnail captions:
> https://github.com/dailydotdev/daily/discussions/927.
> Feel free to push the discussion :)
>
> Personally, I love the diversity of content here on daily.dev and am all for clearly indicating the type of content beforehand.

**@samsamcoder** · 1 upvotes

> I thoroughly enjoyed the video and found the insights to be quite illuminating. Its fair share of challenges, the development community has made significant strides in finding viable solutions. Additionally, the introduction of TypeScript has emerged as a formidable tool, bolstering the JavaScript ecosystem by enhancing type safety and providing a more structured approach to development.

## Similar posts on daily.dev

- [Don’t just attend KubeCon \+ CloudNativeCon, Merge Forward your experience\!](https://daily.dev/posts/don-t-just-attend-kubecon-cloudnativecon-merge-forward-your-experience--l0rpp73x8) · CNCF · 1 upvotes · 0 comments
- [Announcing H2 2026 KCDs](https://daily.dev/posts/announcing-h2-2026-kcds-m96goajm1) · CNCF · 1 upvotes · 0 comments
- [Two months of Open Community Groups](https://daily.dev/posts/two-months-of-open-community-groups-asf52zhbs) · CNCF · 0 upvotes · 0 comments

---

Tags: [#javascript](https://daily.dev/tags/javascript)

[View this post on daily.dev](https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"The Cost Of JavaScript - 2023","url":"https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn"},"datePublished":"2023-06-30T10:01:37.003Z","dateModified":"2023-12-07T12:02:45.284Z","description":"As we build sites that are more heavily reliant on JavaScript, we sometimes pay for what we send down in ways that we can’t always easily see. In this talk,...","image":"https://i.ytimg.com/vi/ZKH3DLT4BKw/sddefault.jpg","thumbnailUrl":"https://i.ytimg.com/vi/ZKH3DLT4BKw/sddefault.jpg","isAccessibleForFree":true,"articleSection":"Community Picks","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Community Picks","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1655817725/logos/community","url":"https://daily.dev/sources/community"},"commentCount":15,"discussionUrl":"https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":162},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":15}],"keywords":"javascript"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Community Picks","item":"https://daily.dev/sources/community"},{"@type":"ListItem","position":3,"name":"The Cost Of JavaScript - 2023"}]}
{"@context":"https://schema.org","@type":"WebPage","@id":"https://daily.dev/posts/the-cost-of-javascript---2023-ccxhhg1fn","comment":[{"@type":"Comment","text":"Can we just get articles?","datePublished":"2023-07-02T17:09:08.591Z","url":"https://daily.dev/posts/CcXhhg1Fn#c-ix9Guzns3","author":{"@type":"Person","name":"Ashish Khare","url":"https://daily.dev/ashuzon","image":"https://lh3.googleusercontent.com/a/AGNmyxY1wooqZum70VfbbDoHcSN18CQf_sMknZtk1oZvdg=s96-c"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":19}},{"@type":"Comment","text":"While it’s not an article, it’s nice to get something like a video or podcast but it would be nice to have a tag so people know when clicking.","datePublished":"2023-07-03T01:41:33.569Z","url":"https://daily.dev/posts/CcXhhg1Fn#c-Gd3BOdpze","author":{"@type":"Person","name":"Hamlet","url":"https://daily.dev/hamlet","image":"https://lh3.googleusercontent.com/a-/ACNPEu80KLMJTyYNcb7YlJZVJ2lRJa0HRendXswD1AnJ=s100"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":10}},{"@type":"Comment","text":"I agree, videos and podcasts, well, any link, should have a snippet of text indicating what it actually is, as some people just want to read.","datePublished":"2023-07-03T04:46:38.986Z","url":"https://daily.dev/posts/CcXhhg1Fn#c-F4pYczpH2","author":{"@type":"Person","name":"Michael Monteleone","url":"https://daily.dev/trivenge","image":"https://avatars.githubusercontent.com/u/10603177?v=4"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":6}},{"@type":"Comment","text":"Hi, I’ve just opened this feature request on thumbnail captions:\nhttps://github.com/dailydotdev/daily/discussions/927.\nFeel free to push the discussion :)\nPersonally, I love the diversity of content here on daily.dev and am all for clearly indicating the type of content beforehand.","datePublished":"2023-07-03T10:31:30.259Z","url":"https://daily.dev/posts/CcXhhg1Fn#c-9L4DcVdoo","author":{"@type":"Person","name":"Anja P","url":"https://daily.dev/anjapcodes","image":"https://media.daily.dev/image/upload/s--M_c0s8Ky--/f_auto/v1721658650/avatars/avatar_WVJSfJtDe63PxQFAsmXFO"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":2}},{"@type":"Comment","text":"I thoroughly enjoyed the video and found the insights to be quite illuminating. Its fair share of challenges, the development community has made significant strides in finding viable solutions. Additionally, the introduction of TypeScript has emerged as a formidable tool, bolstering the JavaScript ecosystem by enhancing type safety and providing a more structured approach to development.","datePublished":"2023-07-07T16:03:12.110Z","url":"https://daily.dev/posts/CcXhhg1Fn#c-pHxFnwBCt","author":{"@type":"Person","name":"Sam Sam","url":"https://daily.dev/samsamcoder","image":"https://media.daily.dev/image/upload/s--qhGaz4lj--/f_auto/v1729538998/avatars/avatar_sJ4QQeFrYw5KbZkH2Mxoz"},"interactionStatistic":{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":1}}]}
```

