A man has been charged with assaulting a fellow resident, who has dementia, at a Sydney aged care facility.

A man will face court from hospital after an alleged attack on another resident in the garden courtyard of the care home.

The attack occurred in a garden courtyard at the home on Wednesday night.