LDB File Documentation
Summary
An LDB file is not a document. It is a temporary Microsoft Access record-locking information file that Access creates automatically next to a database (.mdb) while it is open, to track which users have it open so two people cannot overwrite the same records. You do not open or convert an .ldb: it normally deletes itself when the last user closes the database. If one is left behind after a crash, you can usually just delete it while the database is closed. The modern .accdb equivalent is .laccdb.
Technical details
| Feature | Value |
|---|---|
| Full name | Microsoft Access Record-Locking Information File |
| File extension | .ldb |
| MIME type | application/octet-stream |
| Format type | Temporary lock/state file (binary) |
| Developer | Microsoft |
| Created by | Microsoft Access, when an .mdb database is opened |
| Purpose | Concurrency control — records who has the database open |
| Record size | Fixed 64 bytes per connection |
| Record layout | 32 bytes computer name + 32 bytes Windows user name |
| Maximum size | ~16 KB (255 users × 64 bytes) |
| File signature | None — identified by name and location |
| Naming | Same base name as the database (Sales.mdb → Sales.ldb) |
| Lifecycle | Created on open; deleted when the last user closes the database |
| Safe to delete | Yes — only when the database is fully closed |
| Contains user data | No — no database records, only connection names |
| Modern equivalent | .laccdb (for .accdb databases, Access 2007+) |
| Related extensions | .mdb, .accdb, .laccdb, .ldf |
| Reference | learn.microsoft.com/office/troubleshoot/access/lock-file-information |
What is an LDB file?
LDB stands for “lock database”, and an .ldb file is Microsoft Access’s record-locking information file. It is not a database, not a document, and holds none of your data. Whenever an Access database in the older MDB format is opened, Access creates a companion file in the same folder with the same base name and an .ldb extension — Sales.mdb produces Sales.ldb. Its only job is concurrency control: in a shared database it records which users and computers currently have the file open, so Access can coordinate record and page locking and stop two people from clobbering the same rows at once.
Because it is created automatically and removed automatically, you normally never interact with an .ldb directly. You notice one mainly when it is left behind after something went wrong — a crash, a dropped network connection, or a process that never released the database. Understanding what it contains, and when it is safe to delete, is really all there is to know about the format.
What the lock file records: 64-byte connection entries
The content of an .ldb is a plain list of fixed 64-byte records, one per current connection to the database. Each record is split into two 32-byte fields: the first 32 bytes hold the computer (machine) name that has the database open, and the next 32 bytes hold the Windows user name of that connection. There is no file signature and no header; the file is identified purely by its name and its location next to the database, not by any magic bytes.
Because Access supports up to 255 concurrent users and each entry is exactly 64 bytes, the file is tiny — it tops out at roughly 16 KB (255 × 64 bytes) even for a busy shared database. That fixed layout is also why you can peek inside: opening an .ldb in a text editor (read-only) shows the readable computer and user names of everyone currently in the database, which is a quick way to answer “who has this open?” Do not edit or save the file — it is live state that Access is managing.
The lifecycle: created on open, deleted on last close
The .ldb appears the instant the database is opened and is deleted automatically when the last user closes it. Under normal operation the file exists only for as long as at least one person or process has the database open, and it disappears cleanly afterwards. This is why, most of the time, you should never have to think about it at all.
Problems show up as an orphaned lock file: the database (or the PC) crashed, the network glitched, or a background automation process kept a hidden connection, so the .ldb was never removed. A stray lock file can make Access believe the database is still in use, causing it to open read-only or refuse to open at all, or to report “the database is locked by another user” when the office is empty. The fix is almost always the same: confirm that absolutely nobody (and no scheduled task, script or service) still has the database open, then delete the .ldb. Access recreates it cleanly the next time someone opens the database.
LDB versus LACCDB, and where your data actually lives
The whole .ldb mechanism belongs to the legacy MDB database format. Since Access 2007, the default ACCDB format uses a lock file with the extension .laccdb instead — identical concept, different suffix. So seeing an .ldb rather than a .laccdb tells you the database beside it is an older .mdb.
Either way, the lock file carries nothing you would ever want to recover. Your tables, queries, forms and reports live in the .mdb or .accdb next to it; the .ldb is disposable bookkeeping. There is nothing to “convert” an .ldb into, because it has no data to convert. If you want to upgrade the database itself, open the .mdb in Access and use Save As to produce an .accdb — the lock file is irrelevant to that and simply gets recreated with the new extension.
Is it safe to delete an LDB file?
Yes, with one condition: the database must be genuinely closed by everyone first. An .ldb contains no executable code and nothing sensitive beyond the computer and Windows user names of current connections, so it is harmless to remove once the database is not in use. Deleting it while the database is still open, however, disrupts the active session and can confuse Access’s locking, so never delete it during use. And never delete the .mdb or .accdb itself — that is your real data. If an .ldb keeps reappearing the moment you remove it, that is the file doing its job: someone, or some background process, still has the database open.
Frequently asked questions
Can I delete an LDB file?
Yes, as long as no one and no background process has the database open. The lock file holds no data, so deleting it when the database is closed is safe, and Access recreates it automatically the next time the database is opened. Do not delete it while the database is in use.
Access says the database is locked but nobody is using it — how do I fix it?
You almost certainly have an orphaned .ldb left over from a crash or dropped connection. Make sure no user, script or scheduled task still has the database open, delete the .ldb, then reopen the database; it will be recreated cleanly.
How do I see who has the Access database open?
Open the .ldb in a text editor (read-only). Each 64-byte record lists a computer name and the Windows user name of one current connection, so the file effectively shows everyone who currently has the database open. Do not edit or save it.
References
- Microsoft — Description of the locking information (.ldb) file
- Microsoft Support — Access help and learning
Feedback
Was this page helpful?
Glad to hear it! Please tell us how we can improve.
Sorry to hear that. Please tell us how we can improve.