One of the most stressful calls customer support gets at public charging sites is: "Charging has finished but the cable won't come out." The driver cannot leave the vehicle and has to wait. The UnlockConnector command in OCPP lets you release the lock within seconds without sending a technician.

Why does the cable lock?

On AC chargers with Type 2 sockets, the cable is held inside the socket by a mechanical lock during charging. The lock is there for safety: it prevents the cable from being pulled out while energy flows and stops arcing. Under normal conditions the lock is released when the session ends and the user taps their card, or when the lock on the vehicle side is released. In some cases, however, the lock does not open:

  • The session was ended remotely or by an error, and the charger is waiting for user confirmation,
  • The lock motor or lock sensor is faulty,
  • The charger software has frozen,
  • The lock stayed closed after a power cut.

The lock on the vehicle side is controlled by the vehicle itself; usually you need to unlock the car or press the charge port button. UnlockConnector only releases the lock on the charger side.

Command structure

In OCPP 1.6J, UnlockConnector has a single field: connectorId.

[2, "8001", "UnlockConnector", {"connectorId": 1}]

The charger's possible replies:

  • Unlocked: The lock was released.
  • UnlockFailed: The charger tried but the lock could not be released (mechanical issue).
  • NotSupported: The connector has no locking mechanism or the command is not supported (for example on chargers with a tethered cable).

In OCPP 2.0.1 and 2.1 the command works with evseId and connectorId; the replies can be Unlocked, UnlockFailed, OngoingAuthorizedTransaction and UnknownConnector. OngoingAuthorizedTransaction means the lock will not be released while an active session is running.

What happens during an active session?

In OCPP 1.6J, if UnlockConnector is sent while a transaction is open on the connector, the charger first ends the session (StopTransaction, reason: UnlockCommand) and then releases the lock. So check the session status before sending the command; otherwise you may accidentally end the session of a driver who is still charging.

Step by step for customer support

  1. Get the station and socket details from the driver (QR code or socket number).
  2. Check the connector status in the dashboard: is it Finishing, Charging or Faulted?
  3. If charging is still in progress, ask whether the driver has stopped charging from the vehicle side.
  4. If the session has ended, send UnlockConnector.
  5. If the reply is Unlocked, ask the driver to pull the cable out.
  6. If UnlockFailed comes back, the locking mechanism may be faulty; try a reset once, then dispatch the field team and set the socket to Unavailable.

If UnlockFailed keeps repeating

If UnlockFailed comes back frequently from the same socket, the lock motor, the lock sensor or dirt inside the socket is likely to blame. Taking that socket out of service temporarily prevents other drivers from running into the same problem. See taking a socket out of service with ChangeAvailability. The ConnectorLockFailure error code in StatusNotification signals the same problem; details are in our OCPP error codes guide.

Preventive settings

Some chargers can be configured to release the lock automatically in remotely stopped sessions or when the cable is unplugged on the vehicle side. In OCPP 1.6J the relevant settings are usually the UnlockConnectorOnEVSideDisconnect and StopTransactionOnEVSideDisconnect keys. Configuring these correctly noticeably reduces the number of stuck-cable calls. Details: StopTransactionOnEVSideDisconnect.

Chargers with a tethered cable

On models where the cable is permanently attached to the charger (tethered), there is no lock on the charger side; the cable is locked only on the vehicle side. NotSupported is a normal reply when UnlockConnector is sent to these chargers. If the driver cannot remove the cable, the issue is with the vehicle: locking and unlocking the car, or stopping charging from the vehicle's charging menu, is usually enough. Customer support teams that know this difference avoid unnecessary site visits.

Conclusion

UnlockConnector is a simple but valuable command that solves one of the most frustrating problems in the field remotely. Check the session status before sending the command, act according to the reply code and add recurring lock faults to the maintenance list. Üreticy's OCPP software lets you release a stuck cable's lock from the dashboard with one click and keeps a record of the result of every command.