Helmet laws for motorcyclists are decided by the state governments, not the federal government, so they can differ vastly from one state to the next. They are also subject to change at times; for example, Michigan used to have laws dictating that helmets had to be used, but the state recently dropped that law so that they no longer do. If you live in California or if you plan on riding through, do you need to have a helmet on?
In short, you absolutely do. California law states that all people who ride motorcycles must wear them, and there are no exemptions. Unlike some states, which only require those under 18 to wear them, California has a law making it so that people of all ages have to use them.