Contract laws generally prohibit contracts that restrain trade. Contracts restraining trade are defined as contracts that reduce the level of competition involved in the commercial exchange of goods or services. Contracts that restrain trade are considered a classification of contracts that are contrary to public policy.
These kinds of contracts are sometimes defined by contract laws as covenants not to compete and sometimes as non-competition contracts. Whichever they are known as, though, they are illegal and are thus considered unenforceable.
Elements of contracts that restrain trade are generally permissible if they are limited in scope or duration. A contract is permissible if it compels a party to the contract to relinquish the right to make a particular thing, but not if it attempts to force one of the parties to the contract to not compete with the other in any way in the future.
Contracts are permitted to contain non-competition clauses if the clause exists in order to protect business secrets of the employer, or if the non-competition element of the contract seeks to limit a former employee from utilizing business contacts which are considered essential to the operations of the company with which the original contract was signed.