In California, the written permit test consists of 46 questions. To pass, applicants must correctly answer at least 38 questions, which is an 83% passing score. The permit test currently must be taken at the DMV.
You can refer to our guide to getting a California Learner's Permit which outlines all the steps: https://www.trafficsafetyinstitute.com/learners-permit-california/