Pension for housekeeper

After worked for over 20 years does the housekeeper a legal right for a retirement pension or is it up to,the employer? Thanks