DOM props and forms
defaultChecked prop
Sets the initial selection of an uncontrolled checkbox or radio control. Use checked and a change handler when React state should own the selection.
Formal Syntax & Structure
react syntaxreact
defaultChecked={true}Working Example
Example Snippetreact
export default function App() { return <label><input type='checkbox' name='available' defaultChecked={true}/> Available only</label>; }