WEB DEVELOPMENT · 06 MAR 2026 · READ TIME: 6 MIN
Why most marketing sites ship too much JavaScript
A typical marketing site (hero, a few sections, a contact form) is fundamentally a document, not an application. Yet audit after audit turns up 300–500KB of JavaScript on the homepage, most of it framework and animation-library weight the page never actually needs to be interactive.
The root cause is usually a component library or animation dependency chosen for one section and then imported globally, shipping to every visitor whether they scroll far enough to see the section it powers or not. Nobody decided to ship that weight; it accumulated import by import.
The fix is unglamorous but effective: audit the bundle with a tool like next/bundle-analyzer quarterly, not once at launch, and question every dependency against what fraction of the page actually needs it. Code-splitting and dynamic imports exist specifically so a below-the-fold section's JavaScript doesn't block the first paint.
None of this requires exotic engineering. It requires treating JavaScript weight as a cost that compounds silently, the same way a subscription you forgot about compounds on a credit card statement.
Nikunj Chugh
Growth systems architect: AI automation, media buying, web & SEO.