A controlled component has its form data managed by React state. Inputs are controlled components when their values are linked to state, enabling React to dictate the input’s behavior.
const [inputValue, setInputValue] = useState("");
<input value={inputValue} onChange={(e) => setInputValue(e.target.value)} />;