Skip to content
Bella Bikers

How-to

How to Adjust a Rear Derailleur: Limits, Indexing, B-Gap

Check the hanger is straight, set the high and low limit screws, adjust cable tension with the barrel adjuster until each click moves one cog, then set the B-gap. Here is each step and how to fix common symptoms.

Published · Updated · 9 min read

Close-up of a Shimano rear derailleur

To adjust a rear derailleur, first make sure the hanger is straight, then set the high (H) and low (L) limit screws so the chain cannot fall off either end of the cassette. Next, use the barrel adjuster to set cable tension until each click of the shifter moves the chain exactly one cog, and finish by checking the B-gap. Most poor shifting comes down to cable tension, so that is where small, quarter-turn changes pay off.

This guide follows Park Tool's procedure, with notes from BikeRadar and the manufacturers, plus a troubleshooting chart and a short section on SRAM AXS and Shimano Di2.

How a rear derailleur works

On a cable-operated derailleur, the shifter pulls or releases a set length of cable for each click. A spring inside the derailleur pulls it back the other way. Park Tool notes that on most derailleurs, adding cable tension moves the derailleur inward, toward the spokes and larger cogs.

That gives you four adjustments, each with its own job:

  • H limit screw: how far out (toward the smallest cog) the derailleur can travel.
  • L limit screw: how far in (toward the largest cog) it can travel.
  • Barrel adjuster: fine cable tension, which sets indexing.
  • B screw: the gap between the upper pulley and the cogs.

Limit screws stop the chain going too far. They do not fix poor indexing in the middle of the cassette. That is the barrel adjuster's job.

What you need to adjust a rear derailleur

  • A way to hold the bike with the rear wheel off the ground so you can pedal and shift. A repair stand (search on Amazon, opens in a new tab) is easiest.
  • A small Phillips or flat screwdriver for the limit screws, and hex keys for the cable pinch bolt.
  • A chain that is not worn out. Check it first with our guide on how to check bike chain wear.
  • Optionally, a hanger alignment gauge and new cables if the old ones are frayed.

Step 1: Check the derailleur hanger alignment

Park Tool puts this first for a reason. If the hanger is bent, no amount of screw-turning will make the gears index correctly. Stand behind the bike and look at whether the derailleur cage hangs parallel to the cogs. Even a small bend can cause trouble.

To check properly, Park Tool uses a hanger alignment gauge (search on Amazon, opens in a new tab) threaded into the hanger in place of the derailleur.

  1. Remove the rear derailleur and thread the gauge into the hanger.
  2. Set the gauge's indicator against the rim at the 3 o'clock position, then swing it to 9 o'clock and compare the gap at the same point on the rim.
  3. Repeat at 6 and 12 o'clock, then 9 again.
  4. Park Tool's tolerance: the hanger is aligned when the gap differs by less than 3 mm at three points 90 degrees apart.
  5. To correct it, bend the hanger by about half the measured gap, then recheck. Work in small steps.

Replaceable hangers are designed to bend, but Park Tool warns that one bent repeatedly may break during alignment and need replacing. Hangers integrated into the frame cannot be swapped, so take more care with those. After any hanger work, recheck the limit screws and indexing.

Step 2: Set the high limit (H) screw

  1. Shift to the largest chainring (or the middle ring on a triple) and the smallest rear cog. Keep clicking the shifter until it will not release any more cable.
  2. If the chain will not reach the smallest cog, Park Tool says either the H screw or the cable is holding it. Back the H screw out a few turns. If it still will not shift, turn the barrel adjuster clockwise to slacken the cable. Then turn the barrel adjuster about two more turns clockwise, or until it is fully in, so the cable is not affecting the limit you are about to set.
  3. Adjust the H screw until the upper (guide) pulley sits directly below the smallest cog.
  4. Pedal and listen. Tighten the screw in small steps until the chain starts to rub on the next cog, then back it out in quarter turns until the noise stops. If two settings are equally quiet, Park Tool says choose the tighter one.

BikeRadar's alternative is to set the H screw with the cable disconnected, which takes cable tension out of the picture entirely.

Step 3: Set the low limit (L) screw

The L screw is a safety setting. Too loose, and the chain can go over the largest cog into the spokes.

  1. Shift to the largest rear cog. On a 2x bike, Park Tool uses the second-largest chainring.
  2. Watch for signs that the L screw is too tight: the chain will not reach the largest cog, the shift is slow, or it is noisy.
  3. If none appear, Park Tool's method is to tighten the L screw a full turn at a time and retest until they do, then back it out a quarter turn at a time until the symptoms just disappear.
  4. Push the shifter a little harder in the largest cog. The derailleur cage should not move any further inward.

Park Tool actually sets the L screw last, after indexing. Either order works as long as you finish with the push test.

Step 4: Set cable tension and indexing with the barrel adjuster

This is where most shifting problems are fixed.

  1. Start from a known point. If you disconnected the cable, BikeRadar suggests setting the barrel adjuster one or two turns out, pulling the cable taut and tightening the pinch bolt, usually to about 5 Nm. New cables stretch slightly, so shift through the gears a few times and recheck.
  2. Shift one click from the smallest cog while pedaling at a normal cadence.
  3. If the chain does not move up, Park Tool's fix is to shift back and turn the barrel adjuster counterclockwise one full turn, which adds tension. Repeat until it shifts.
  4. If one click jumps two cogs, turn the barrel adjuster clockwise a full turn to reduce tension.
  5. Fine-tune with quarter turns. Move through each cog one click at a time, listening for chain noise from the next-larger cog. Park Tool's direction is a quarter turn clockwise when you hear that noise or when shifts back down to smaller cogs are slow.
  6. Check the full range in both directions, including the first three cogs, which BikeRadar uses as its quick test.

If the barrel adjuster runs out of thread, screw it fully in, back it out one or two turns, and take up the slack at the pinch bolt, as Park Tool describes.

Step 5: Set the B-tension (B-gap)

The B screw changes the angle of the derailleur body and so the distance between the upper pulley and the cogs.

  1. Shift to the smallest chainring and the largest rear cog.
  2. Measure the gap between the upper pulley and the cog. Park Tool and BikeRadar both say most road and mountain derailleurs need about 5 to 6 mm. A hex key of the right size makes a quick gauge.
  3. Tighten the B screw to increase the gap; loosen it to reduce it.
  4. After a big B-screw change, recheck indexing.

Check your derailleur's manual for its own figure. BikeRadar lists 5 to 7 mm for Campagnolo Super Record Wireless, and BikeRadar suggests SRAM's own B-gap tool for AXS derailleurs. SRAM's Eagle Transmission derailleurs have no H, L or B screws at all; SRAM says their direct-mount design is set up with a setup key and a specific cog instead. If you are changing cassette size, see rear derailleur capacity and max cog first, because B-gap cannot make a derailleur work with a cog larger than it was designed for.

Rear derailleur troubleshooting chart

SymptomLikely causeFix
Will not shift to larger cogs, or slowCable too slackBarrel adjuster counterclockwise, quarter turns
Slow shifts to smaller cogsCable too tight, or cable frictionBarrel adjuster clockwise; replace worn cable
Chain rattles against the next larger cogCable too tightBarrel adjuster clockwise, quarter turn
One click moves two cogsCable too tightBarrel adjuster clockwise, one turn
Will not reach smallest cogH screw too tight or cable too tightBack out H screw; check cable tension
Chain falls off smallest cogH screw too looseTighten H screw
Will not reach largest cogL screw too tightBack out L screw, quarter turns
Derailleur moves past largest cogL screw too looseTighten L screw; check for spoke damage
Indexing will not come right in every gearBent hangerCheck and align hanger
Upper pulley under about 5 mm from largest cogB-gap too smallTighten B screw
Skips under load after adjustingWorn chain or cassetteMeasure wear; replace as needed

The causes and fixes above follow Park Tool's adjustment and hanger procedures. BikeRadar's troubleshooting list adds a few more checks when adjustment alone does not work: chain and cassette wear, frayed cables and split housing, loose derailleur, cassette or crank bolts, and worn derailleur pivots or shifter internals.

When to replace the shift cable and housing

Park Tool says kinked, frayed, rusty or dirty cables and housing cause slow, inconsistent or hard shifting, or no shifting at all. If the barrel adjuster seems to fix a problem one day and not the next, or shifting feels gritty, fit a new shift cable and housing (search on Amazon, opens in a new tab) before adjusting further. Use compressionless shift housing, not brake housing, as Park Tool advises for indexed systems. After a new cable, expect to recheck tension after the first ride or two.

Adjusting SRAM AXS and Shimano Di2 derailleurs

Electronic derailleurs still have limit screws and a B-gap, but there is no cable, so indexing is adjusted in software.

SRAM AXS MicroAdjust

SRAM's road guide says MicroAdjust moves the rear derailleur in 0.25 mm steps. You can do it in the AXS app under the bike's drivetrain settings, or by holding the shifter's AXS button and pressing a shift paddle. On road levers, the left shifter moves the derailleur inboard and the right moves it outboard. Make one step at a time and pedal to check.

BikeRadar's setup order for AXS is pairing first, then the B-gap (ideally with SRAM's tool), then the limit screws. It also warns not to push SRAM electronic derailleurs by hand, because that can damage the motor. SRAM's own advice is that if you are using MicroAdjust to compensate for a bent derailleur or hanger, check the limit screws so it cannot overshift into the spokes.

Shimano Di2 adjustment mode

On wired 11-speed Di2 road groups, BikeRadar's method is to press the junction box button until the red light comes on, then use the rear shift buttons to move the derailleur while you turn the cranks, and press the button again to exit. BikeRadar's derailleur guide adds that the 12-speed Di2 process starts in the eighth cog and sets the B-gap first. Shimano's E-TUBE app can also enter adjustment mode.

For Di2 limit screws, BikeRadar's guide says to tighten the low screw on the largest cog until it just touches the linkage, and the high screw on the smallest cog until it touches, then back it out a full turn. It warns that incorrect limit settings can drain the battery and damage the derailleur.

For a broader comparison of cable and electronic systems, see electronic vs mechanical shifting.

Keep it running

Once set, a derailleur usually needs only small tweaks, but a new cable, a stretched old one or a knock to the derailleur can all put it out. A quick shift through the gears is part of our bike maintenance checklist. If a fresh chain is what triggered the problem, our guide on how to replace a bike chain covers sizing it correctly, which affects shifting too.

Frequently asked questions

Which way do I turn the barrel adjuster?

Turning the barrel adjuster counterclockwise, out of the derailleur, adds cable tension and helps shifts toward the larger cogs. Turning it clockwise reduces tension and helps shifts toward the smaller cogs. Work in quarter turns and test after each one.

What do the H and L screws do?

They set how far the derailleur can travel. The H screw stops it moving past the smallest cog into the frame, and the L screw stops it moving past the largest cog into the spokes. They do not affect indexing between the middle gears.

What should the B-gap be?

Park Tool and BikeRadar both say most road and mountain derailleurs need about 5 to 6 mm between the upper pulley and the cog. Campagnolo specifies 5 to 7 mm for Super Record Wireless. Some systems, such as SRAM Eagle, use their own gauge or setup cog, so check the manual.

Why do my gears skip even after adjusting?

Skipping under load often means a worn chain or cassette rather than bad adjustment. A bent hanger, frayed cable or loose cassette lockring can cause it too. Check chain wear and hanger alignment before chasing the barrel adjuster.

How do I adjust SRAM AXS or Shimano Di2 gears?

Electronic systems replace the barrel adjuster with a software adjustment. SRAM AXS uses MicroAdjust from the shifter or app, in 0.25 mm steps on road derailleurs. Shimano Di2 has an adjustment mode entered from a button or the E-TUBE app.

About this guide

Written by

Drivetrain & Compatibility Desk

Bella Bikers Editorial Team

Chains, cassettes, derailleurs, cranks and bottom brackets, and the question we hear most: will this part work with that one?

How this was made: Written by our Drivetrain & Compatibility Desk from manufacturers' service manuals, technical documents and published standards, then checked by an editor before publishing. Where makers disagree, the guide says so. This is a reference guide, not a product review.

Published · Last updated · Editorial guidelines · Report an error

Everything in Guides