Smart Lock Code Generator
Generate per-booking lock codes you can re-derive on demand. Same booking ID + secret produces the same code, every time.
| Booking ID | Lock code |
|---|
These codes are deterministic — the same booking + secret always produces the same code. Store your secret somewhere safe (a password manager). Rotate it if it leaks.
How it works
We compute HMAC-SHA-256 of your booking ID using your secret as the key, then take the result mod 10^digits and zero-pad to length. The output is deterministic and unique-by-booking — no storage required.
How to use this tool
- Pick a strong host secret (treat like a password).
- Choose your code length (4-8 digits, depending on lock model).
- Paste your booking IDs — one per line.
- Copy each code into your lock app or PMS.
FAQ
Is the code unique to each booking?
Yes. Same booking ID + secret -> same code; different booking ID -> different code.
Why deterministic?
You can regenerate the same code at any time without storing it — useful when guests forget or your PMS loses the value.
How is the code computed?
HMAC-SHA-256 of the booking ID using your secret as the key, taken mod 10^digits.
Is my secret stored anywhere?
No. It only lives in your URL while you use the page. Treat it like a password.
Can I use 4-digit codes?
Yes. The tool supports 4-8 digit codes. Most smart locks accept 4-8.
Consumer-friendly, retrofits most deadbolts, integrates with Hostfully + OwnerRez.
Check it out →Commercial-grade keypad lock, Apple home key support.
Check it out →Multi-platform lock management; works with most PMS systems.
Check it out →