Four years for written contracts under CCP §337, and two years for oral contracts under CCP §339, measured from the date of the breach. Different deadlines apply to fraud, mechanic’s liens, public works claims, and certain construction defect actions. When the deadline is close, treat the matter as urgent.