This is a question only the Building/Planning dept at City Hall would be able to answer for you........I also think that this would perhaps only be a case by case consideration.....depending on the neighborhood zoning in place. If you have a Lot in mind, check directly with the City, as they lay down the zoning regulations.......I worked on the City's General Plan as a appointed Volunteer few years ago.
I am a Public Safety commissioner with the City of Cupertino, and have done contract jobs and tons of volunteer work with the City......worked closely with all the depts there....tone of us have the authority to answer this question......
Wishing you the Best, Do get in touch with me if I can help with any Real Estate needs.
Be well and Safe, Regards,