Different localities have different laws regarding guns and gun ownership. You should check with your local law enforcement to see what the laws are in your area. In California, it is illegal to possess a “detachable magazine” that holds more than ten rounds of ammunition. This law applies to both firearms and devices that can be readily converted into firearms, such as 3D-printed gun parts.
It is also illegal to possess a “multi burst trigger activator,” which is defined as “any device designed or redesigned to control the rate of semiautomatic fire.” These devices are also known as bump stocks.
Finally, California has a law prohibiting the possession of unsafe handguns. An unsafe handgun does not meet certain safety requirements, such as having a magazine disconnect mechanism. If you have any questions about whether a particular gun or gun part is legal in California, you should consult with an attorney who is knowledgeable about firearms law.