423 Client Error ๐Ÿ“‹

423 Locked: Resource Is Locked (WebDAV)

Last updated: June 28, 2026 โ€ข 4 min read

โœฆ The Golden Answer: The 423 Locked status code indicates that the requested resource is locked (typically in WebDAV). This means the resource is currently being edited or held by another user or process, and the client must unlock it before making the request. The server returns this status when a client tries to modify a resource that has an active lock (e.g., using the LOCK method). To resolve, the client must obtain the lock token and unlock the resource using the UNLOCK method.

How Locking Works in WebDAV

WebDAV (Web Distributed Authoring and Versioning) extends HTTP to support collaborative editing. It uses:

  • LOCK โ€“ to lock a resource, preventing others from modifying it.
  • UNLOCK โ€“ to release the lock.
  • Lock tokens โ€“ unique identifiers that represent the lock, passed in the If header to prove ownership.

If a client tries to PUT, POST, or DELETE a resource that is locked by another client, the server returns 423 Locked.

Common Causes of 423 Errors

CauseExampleHow to Fix
Resource locked by another userAnother client holds a lock on the resource.Wait for the lock to be released or contact the user who holds the lock.
Stale lock not releasedPrevious user crashed without releasing the lock.Use a lock manager to forcibly release stale locks, or implement timeouts.
Client lacks lock tokenClient tries to modify but doesn't include the lock token in the If header.Obtain the lock token and include it in the request.
Server misconfigurationServer lock management is broken.Fix server configuration or implement proper locking logic.

Example: 423 Response

A client attempts to PUT a file that is locked by another user:

PUT /docs/report.pdf HTTP/1.1 Host: example.com Content-Type: application/pdf [data] HTTP/1.1 423 Locked Content-Type: text/html <html> <body> <h1>423 Locked</h1> <p>The resource is locked by user 'alice' (lock token: <urn:uuid:123...>).</p> </body> </html>

How to Fix 423 Errors

  • If you're a client: Check if you hold the lock. If not, obtain the lock token via LOCK and include it in the If header. If you are the lock owner but don't have the token, you may need to unlock and reโ€‘lock.
  • If you're a server developer: Implement proper lock management. Use timeouts to automatically release stale locks. Send clear error messages that include the lock owner and token.
  • If you're an endโ€‘user: This error is rare outside WebDAV clients (e.g., Microsoft Office, file managers). Contact the person who locked the file or your system administrator.

Related WebDAV Codes

  • 207 Multi-Status โ€“ used for batch operations.
  • 424 Failed Dependency โ€“ used when a previous operation in a batch fails.
  • 507 Insufficient Storage โ€“ server out of space.

Frequently Asked Questions

Is 423 a client error or a server error?

It's a client error (4xx) because the client's request cannot be fulfilled due to the resource being locked. However, the lock is a serverโ€‘side state, so it's a conflict between the client's intention and the server's current state.

Can I use 423 outside of WebDAV?

Technically yes, but it's designed for WebDAV. In REST APIs, you might use 409 Conflict or 422 Unprocessable Entity for similar cases (e.g., resource being edited).

What is a lock token?

A lock token is a unique identifier (usually a URI) that represents a specific lock. It is used to prove ownership of the lock when performing operations on the locked resource.