Where should UI modal state live in React?
In local useState, in the component that owns the modal. Do not put UI flags in Redux or Context; that is overuse. Local state keeps the modal simple and scoped to where it is used.
Verify This Answer
Cross-check this information using these trusted sources:
More FAQs in Redux vs useState for a Netflix Clone: Choosing State in React
Only for genuinely complex, frequently-updated shared state like a watchlist. Movie data, auth, search, and modals can be handled with useState, Context, and React Query. Do not default to Redux; use the simplest tool that works.
In Context. Auth is shared across the whole app but changes rarely, so Context is sufficient without Redux's overhead. It is built into React and perfect for user state like this.
As server state with React Query or fetch in useEffect. It does not need Redux unless other parts of the app heavily interact with it. Server state tools handle caching and invalidation for you.
Still have questions?
Browse all our FAQs or reach out to our support team
