In California, your landlord has to provide you with a rental unit that's fit for human habitation. This means it has to meet building and health codes. If something in the rental unit breaks down, your landlord may have to fix it. If he refuses to conduct repairs, you might have the right to take serious action, depending on the circumstances.
Significance of Problem
You have the right to withhold rent or repair and deduct only if the problem that the landlord refuses to fix is serious enough to affect your health or safety. It can't be just an annoying or uncomfortable problem with the rental unit. For example, serious problems would occur if your rental unit becomes uninhabitable because the windows are broken, you don't have hot water or your heating facilities are broken. However, if the landlord refuses to fix a broken faucet, you can't take an extreme measure such as withholding rent or repairing and deducting. You also can't do either method if you or your guest caused the damage in the first place.
Before you force your landlord to fix the problem, you have to give him enough notice and time to do it. You should notify the landlord of the problem in writing and ask him to repair it. In the letter, include what the problem is, how it affects you and what you want him to do about it. Submit a written request in person or by certified mail even if you have called or emailed your landlord; the receipt will serve as evidence if he refuses to fix it. In California, your landlord usually has an obligation to fix a habitability problem within 30 days, but the time limit is shorter for urgent repairs.
Repair and Deduct
If the problem affects your health or safety, you have the option of making the repairs yourself and deducting the cost from your rent. You should give the landlord enough time to fix the problem. If he refuses to do so, you can choose to purchase any required parts and fix the defect yourself. Alternatively, you can hire a professional to fix the problem. There are limitations to this solution: you can't deduct more than one month's rent and you can only do this twice in any 12-month period.
If the problem is more serious than you can fix with a "repair and deduct" solution, you may be able to withhold rent. Before you actually withhold rent, let your landlord know that you intend to do so if he fails to repair the problem. In many cases, withholding rent does not mean you can stop paying rent altogether. Instead, you should only reduce the amount of rent you pay the landlord based on the effect of the defect on the rental unit. Some cities in California require that you pay the withheld amount to a city escrow account. You can only stop paying rent altogether if the problem is so bad that you have to move out of the rental unit.