The California Business and Professions Code provides that any contract that restrains anyone from engaging in a lawful profession, trade, or business of any kind is to that extent void. (Bus. & Prof. Code, § 16600)
That's right, that means all those employee agreements you found on the internet that said "you can't compete with us for 10 years after your termination" is probably void. In fact, there are repercussions beyond it just being void but also possible labor law violations that may lead to fines or open your company up to high risk liability.
There is a savior here as it is recognized that in certain exceptions to the general rule for restriction on competition, where a trade secret or the use of confidential proprietary information is involved, a covenant not to compete will be considered valid and enforced to the extent necessary in order to protect relevant trade secrets. Thus, a former employee may engage in a competitive business only as long as the competition is fair and legal.