Context is React's built-in mechanism for sharing data across the entire component tree without prop drilling.
1The Drilling Problem
As applications grow, passing data through multiple layers of components becomes unsustainable. This 'Prop Drilling' makes components hard to reuse and even harder to maintain. Context solves this by creating a data 'broadcast' system. Instead of passing a bucket down a line of people, you put the water in a central tank that everyone can tap into directly.
2Performance & Reactivity
One of the most powerful features of Context is its reactivity. When the value prop of a Provider changes, React automatically identifies every component that is consuming that context and triggers a re-render. This ensures your UI is always in sync with your global state, whether it's a theme switch, a language change, or an updated user profile.
