1. Remove the rear door unit.
2. Remove the screws, then remove the rear door latch and lock actuator.

3. Install in the reverse order of removal.
Front door latch and lock actuator removal/installation
Front door key cylinder removal/installationMazda 6 Service Manual: Rear door removal/installation
Warning
Handling the side air bag sensor improperly can accidentally
deploy the side air bag module, which may seriously injure you. Read AIR BAG
SYSTEM SERVICE WARNINGS before working around the B-pillar areas. (See
SERVICE WARNINGS.)
Note
The side air bag sensor is located in t ...
Mazda 6 Service Manual: Immobilizer system reprogram procedure
Note
When an error occurs during the reprogram procedures, except when
the PCM is replaced, repeat the procedure from Step 1. If you still cannot
reprogram, confirm how many keys can start the engine. Then, perform the key
replacement or addition reprogram procedure according to the val ...