Where does the Women should be seen not heard phrase come from?

Forgive my ignorance but I’ve heard this phrase a lot from various arsehats throughout my life but I’ve never understood where it originated from. Is it an old sexist saying from medieval Europe that refused to die?
Where does the Women should be seen not heard phrase come from?
Post Opinion