California legislators on Wednesday passed a bill that requires major companies based in the state to put female directors on their boards.

If the bill is signed into law by Gov. Jerry Brown, a Democrat, publicly traded companies based in the state will need to have at least one woman on their boards by the end of next year and, on boards of five or more directors, two or three women by the end of 2021, depending on the board’s size. Those that don’t would face financial penalties.