A resistor and capacitor connected in series is the most frequently used "time-making" device in electronic circuits. Filtering out switch jitter, waiting a moment after power comes on before starting, removing noise from a signal, and setting the time of a 555 timer all come from the same principle. This article covers the charge and discharge curves of an RC circuit, the time constant τ (tau), the 63% and 95% rule, the cutoff frequency, and how to decide values. The RC time constant calculator helps with the calculations.
Intuition: filling a bucket with water
It is easy to think of the capacitor as a bucket that holds water and the resistor as a narrow pipe the water passes through. The narrower the pipe (the larger R) and the bigger the bucket (the larger C), the longer it takes to fill. At first the bucket is empty so water goes in quickly, but as it fills the pressure difference shrinks and it slows down. That is why the charging curve is not a straight line but a curve that gets gentler and gentler.
Charge and discharge curves
When a supply voltage Vs is connected through R to an empty capacitor, the capacitor voltage changes as follows.
Charging: Vc(t) = Vs × (1 - e^(-t/τ)) Discharging: Vc(t) = V0 × e^(-t/τ) τ = R × C
τ is a "unit of time". After 1τ, charging reaches about 63.2% of the final value, about 95% at 3τ, and about 99.3% at 5τ. In general, after 5τ it is considered "fully charged (or discharged)". The time to reach a ratio you want is found with t = −τ × ln(1 − ratio); for example, 90% takes about 2.3τ.
Deciding values
Work backward from the time you want to get R and C.
- Decide the delay time t you want and the ratio to reach (for example, 90%).
- Find the τ you need:
τ = t ÷ 2.3(for 90%). - Pick C first (0.1 µF to 100 µF is easy to handle) and calculate
R = τ ÷ C. - Check that R falls within 1 kΩ to 1 MΩ. If not, adjust C.
For example: to reach 90% after 0.5 seconds, τ = 0.22 s, and with C = 10 µF, R = 22 kΩ.
Use 1: Delay and reset
Putting an RC on an IC's reset pin keeps it Low for a moment right after power comes on so it starts from a stable state. The arrangement charges the reset pin from +V through a resistor with the capacitor going to ground. The time for the reset pin voltage to climb to the threshold after the supply rises is the delay time.
Use 2: Filter
A capacitor to ground after a resistor makes a low-pass filter. The cutoff frequency is as follows.
f_c = 1 / (2π × R × C)
With R = 10 kΩ and C = 100 nF, f_c ≈ 159 Hz. Signals that change faster than this are gradually weakened. It is used for removing noise from sensor signals, in front of ADC inputs, and in simple DACs that turn a PWM signal into a flat voltage. If you swap the capacitor and resistor positions (with the capacitor in the signal path), it becomes a high-pass filter that blocks low frequencies.
Use 3: Switch debounce
Jitter from a mechanical switch usually lasts 5 to 20 ms. Putting R = 10 kΩ and C = 100 nF (τ = 1 ms) on the switch pin smooths the jitter out. However, when an ordinary input reads a slowly changing voltage, it can wobble near the threshold, so it is safer to use it together with a Schmitt trigger input (Tact Switches and Pull-Up/Pull-Down Resistors).
Use 4: The 555 timer
The 555's times are all set by RC. The monostable output time 1.1 × R × C and the astable period 0.693 × (R1 + 2R2) × C are the times for the capacitor to travel between 1/3 and 2/3 of the supply (555 Timer Monostable Circuit, Astable Circuit).
What to watch with real parts
- Capacitor tolerance: electrolytic capacitors vary by ±20% or more, so the calculated time varies by the same ratio. For accurate timing use a film or C0G ceramic.
- Leakage current: using a large resistor (several MΩ) together with an electrolytic capacitor lets leakage current interfere with charging, and it may not reach the target voltage.
- Loading effect: if you connect another circuit to the RC output, that circuit's input resistance acts in parallel with R and changes the time and final voltage.
- Discharge path: if the capacitor needs to discharge quickly after power is off, a discharge resistor is needed.
Summary
The time scale of an RC circuit is τ = R×C, reaching 63% at 1τ, 95% at 3τ, and 99% at 5τ. The cutoff frequency is 1/(2πRC). Work backward from the target time to τ to choose R and C, and use a capacitor with a small tolerance if you need precise timing. Continue with the types of capacitors in Capacitor Types, Polarity, and Reading Values.