Salesforce Dictionary - Free Salesforce GlossarySalesforce Dictionary
Salesforce Developer
easy

What's the difference between Lightning Web Components (LWC) and Aura Components?

Both are Salesforce's UI component frameworks but represent different generations.

Aura (older, 2014) — Salesforce-proprietary component framework. Uses .cmp markup files, controllers in JS+helper.js, server-side Apex via attributes. Built on a custom rendering engine.

LWC (newer, 2019) — based on the Web Components standard (Custom Elements, Shadow DOM, ES Modules). Looks and feels like modern frontend code: TypeScript-style classes, decorators (@api, @track, @wire), template files (.html).

Differences:

  • Performance: LWC is faster — uses the browser's native rendering rather than a custom engine.
  • Standards: LWC is closer to standard JavaScript; developers transfer skills from React/Vue more easily.
  • Tooling: LWC works with VS Code, Jest for unit testing, ESLint. Aura tooling is more limited.
  • Composition: LWC components can wrap Aura components but not vice versa (in some scenarios). Mixed apps work.
  • Bundle size: LWC components are leaner, load faster.
  • Future: LWC is the strategic direction. New work should be LWC; Aura is for maintaining existing components.

When you'd still touch Aura: maintaining an existing Aura-heavy codebase, or for the few platform features that haven't migrated to LWC yet.

Why this answer works

Tests UI fluency. Recommending LWC for new work and recognising Aura is legacy is the modern position.

Follow-ups to expect

Related dictionary terms