A servo that’s supposed to hold still, or move smoothly to a position, instead twitches back and forth in tiny movements — sometimes constantly, sometimes only when it’s meant to be idle. It’s rarely a broken servo. Almost every case traces back to one of a small handful of causes, and the fastest way to the fix is working out which category it’s actually in rather than guessing.
Power supply issues — the most common cause by far
Covered in more depth in the SG90 pinout and wiring guide, but it’s worth restating as the first thing to check: a servo drawing power from a microcontroller board’s onboard 5V regulator, especially more than one servo at once, is the single most common cause of jitter. The regulator can’t supply the current spikes a servo draws while moving, the supply voltage sags, and the servo’s own control electronics — which need a stable voltage to interpret the position signal correctly — start behaving erratically as a direct result.
The fix: power servos from a separate, dedicated 5V supply rated for real current (not just the microcontroller board’s onboard regulator), with the ground tied back to the microcontroller’s ground. If jitter disappears the moment power is switched to a separate supply, this was the cause.
A noisy or floating signal wire
The servo reads its target position from pulse width on the signal wire, and if that signal is noisy, disconnected, or shares a long unshielded run alongside a motor or relay wire, the servo can receive garbled pulse widths and visibly hunt around trying to match a target that’s jumping around. This shows up as a fine, rapid, buzzing-type jitter rather than the larger, slower twitch typical of a power problem.
The fix: keep the signal wire short, route it away from motor and relay wiring, and if it must run any distance, a common trick is adding a small (~0.1–1µF) capacitor across the servo’s power and ground right at the servo end to smooth out local supply noise the signal circuitry is sensitive to.
Code sending the wrong pulse width, or sending one continuously when it shouldn’t
If a sketch calls a servo library’s write function every loop iteration — even with the same target angle each time — some libraries or servo/driver combinations re-issue the PWM pulse constantly, which on some servos causes a visible small twitch as the internal control loop is repeatedly re-triggered rather than left alone once the target is reached. Related: a target angle sent slightly beyond a servo’s real mechanical range asks it to push continuously against its own end-stop, which can look and sound exactly like jitter but is actually the servo straining against something it physically can’t do.
The fix: only send a new position command when the target angle actually changes, and confirm (per the SG90 pinout guide) that the pulse-width range being sent matches what the specific servo actually supports rather than assuming every servo’s endpoints are identical.
A worn or damaged potentiometer inside the servo
A standard hobby servo uses a small internal potentiometer to sense its own shaft position and feed that back into its control loop. If that potentiometer’s wiper is worn, dirty, or the servo has taken a mechanical knock, the position feedback becomes noisy at the source, and the servo’s own control loop jitters trying to correct against a feedback signal that isn’t stable — no amount of clean external power or signal fixes this, because the problem is internal.
The fix: if jitter persists even with a known-good separate power supply, a clean signal, and code confirmed to only send stable position commands, swap in a different servo of the same type and compare. If the replacement is smooth under identical wiring and code, the original servo’s internal potentiometer (or gear train) is the actual fault, and it’s not economically worth repairing on a part this cheap.
A quick way to narrow it down
Isolate one variable at a time rather than changing several things at once: first swap to a separate, adequately-rated power supply and see if jitter changes. If it doesn’t, check the signal wire routing and shorten it if possible. If it still jitters with clean power and a short signal wire, suspect the code sending redundant or out-of-range commands. If none of that resolves it, suspect the servo itself. Working through them in that order matches how common each cause actually is — starting with the servo itself is usually the least productive place to start, even though it’s often the first thing people suspect.