The words we type every day are usually dead metaphors. Nobody thinks about a physical desktop, or a real folder, or an actual window. But log in is a strange one, because two completely different things in your system carry the same word: the thing users do at the front door, and the JSON lines your server writes to stdout. They are the same word for a reason, and the reason is a piece of wood on a rope.
I went looking for the primary source. It turns out to be more interesting than the trivia version, because the manual where login first appears in print doesn’t have a password in it.
The Wooden Part
Start with the object. Log meaning ‘a lump of wood’ shows up in English in the early 14th century, and its origin is honestly unknown – etymonline records the obvious guess (Old Norse lág, ‘felled tree’) and notes that etymologists dispute it on phonological grounds. One of the alternative theories is that the word was simply invented to sound heavy. So the root of the whole family is a word nobody can explain, and everything downstream of it is documented to the year.
Here’s the downstream. Before satellites, a ship out of sight of land had one way to know where it was: dead reckoning. Take your last known position, your heading, your speed, and the time elapsed, and calculate where you must be now. Heading came from the compass and time from the glass – but speed had no instrument, so sailors built one out of the cheapest material on board.
The chip log was a quarter-circle board of wood, five or six inches across, weighted along its curved edge so it floated upright, tied to a long reeled line. You threw it off the stern. The board caught enough water to stay roughly where it landed while the ship sailed away from it, so the line paid out at exactly the speed of the ship. The line had knots tied at fixed intervals. One sailor turned a half-minute sandglass, another counted the knots running through their hands, and the count was the speed. That’s the whole instrument: a piece of debris, a string, and a timer.
It’s also where the unit comes from. A ship doing eight knots is a ship that pulled eight knots of line through someone’s fingers in half a minute. The first known description in print is William Bourne’s A Regiment for the Sea, 1574, and the sense of ‘knot’ as a unit of speed is recorded by the 1630s.
Now the important part. A speed measured at 4 p.m. and then forgotten is worthless – dead reckoning needs the whole sequence. So the readings went into a book: heading, speed, time, one entry after another, watch after watch. That book was named after the instrument that fed it. Log-book is recorded from the 1670s, the verb to log – to enter something into that book – from 1823, and by 1842 sailors had clipped the noun down to just log.
So the semantic move that matters happened at sea, and it happened early: the log stopped being the wooden thing and became the record. And the record existed for one purpose – to reconstruct a position that nobody could observe directly.
That is a description of a log file. It was a description of a log file 150 years before there were computers.
The 1963 Part
The computing sense arrives with a specific, citable document: The Compatible Time-Sharing System: A Programmer’s Guide, F. J. Corbató et al., MIT Press, preface dated May 1963. 1963 is the earliest computing-sense date the dictionaries give for log in, and this is the manual that date points to – I haven’t opened the OED entry myself, but I have read the manual, and the whole thing is scanned on bitsavers.
CTSS was one of the first time-sharing systems – a room-sized 7094 that many people used at once through consoles, instead of one person at a time submitting a deck of cards. Once a machine is shared, you need to know whose session is whose. Page 69 of the guide describes the command that solved it:
login α β
α = user problem number
β = user programmer numberRead the two parameters carefully. A problem number and a programmer number. Not a username and a password – an account code and a person code. The manual says the command should be given at the beginning of each session, that it clears the time accounting records, and that it logs out whoever used the console before you.
And then, a paragraph later, the guide notes that ‘in the future an additional parameter may be required’ for greater security – probably a private code, given separately.
That’s the password. In May 1963 it was a future feature. login shipped first.
The closing bracket makes the point even better. The logout command’s job, per the same page, is to write the user’s file directory back to disk and prepare usage accounting records for the system. And the sample session at the back of the book, Appendix A, ends with the machine printing the user’s ID, the date, the time, and a total: TOTAL TIME USED= 01.6 MIN.
Look at what that pair of commands actually is. login opens an entry – who, when, meter reset to zero. logout closes it – who, when, and how much was consumed in between. Structurally, that’s a ledger: it looks remarkably like a watch entry in a ship’s log, applied to a scarce resource that many people are drawing on, which in 1963 was CPU seconds on a machine that cost more than a building.
Be precise about what that does and doesn’t establish. The manual proves the function: on this system, in May 1963, the command was about identifying a session and metering it, and the security parameter was still hypothetical. It does not prove intent – nobody at MIT left a note saying they picked the word because they were thinking of a bookkeeper’s ledger or a mate’s watch entry. The word arrived carrying two centuries of ‘write it in the book,’ and the operation it named happened to be exactly that shape. Whether that was deliberate or convergent, I can’t tell you, and neither can the sources.
What the source does support is the useful half: on the system where the word entered computing, login was an accounting artifact before it was a security artifact. The authentication we now assume the word means was bolted on afterward – one history of CTSS security dates the arrival of passwords to around May 1964, citing the project’s own Time Sharing System Notes – because it turned out that a ledger anyone can write any name into isn’t much of a ledger.
(The CTSS veterans’ 50th-anniversary memoir suggests the username/password method itself may have originated there – but the person saying it explicitly flags it as ‘without confirmatory research,’ so treat it as a strong hint and not a settled first.)
The vocabulary split later. Logon shows up as a computing term by 1975 and became the IBM mainframe convention – TSO users still log on. Unix took login, and the single-word noun login is recorded by 1983. Two dialects, one wooden ancestor.
Why This Should Change What You Log
This is where the etymology stops being trivia, because most auth logging I see is built on the wrong mental model. If you think log in means ‘authenticate,’ you log the authentication: one line, one timestamp, user X signed in. That’s a doorbell, not a ledger.
The 1963 design was better, and it’s better for reasons that still apply.
Log the pair, not the event. CTSS closed every entry – logout wrote the total. Most systems I audit log sign-ins and lose sign-outs, because a sign-out is often just a cookie expiring and nobody wired an event to it. The result is an audit trail full of open brackets: you can tell me a session started at 02:14, but not whether it lasted four seconds or four days. A watch entry with no closing time doesn’t tell you where the ship went. Emit a session-end record – on explicit logout, on expiry, on revocation – and put the duration and the reason in it.
CTSS had it easy here: a console session ended when someone typed logout. Yours often doesn’t end at all in any observable way. The process dies, the laptop lid closes, the phone loses signal, the token quietly ages out on a machine nobody is watching. So don’t design for perfectly closed pairs – design so the record distinguishes an observed end (logout, revocation, forced sign-out) from an inferred one (expiry swept by a job) from no known end at all. An audit trail that silently backfills a plausible end time is worse than one with honest open brackets, because now you can’t tell which sessions you actually watched close.
Log the fields you’d want in a ledger, and no more.
// a session record that is actually useful later
logger.info(
{
event: "session.end",
sessionId, // correlates with session.start
userId, // an internal ID, not an email
reason: "expired", // "logout" | "revoked" | "replaced" (observed)
// vs "expired" | "unknown" (inferred — say which)
durationMs,
ip,
ua,
},
"session ended"
);Named fields, chosen on purpose. Never a spread of the whole request or the whole user object – that’s how an Authorization header, a session token, or a password reset link ends up sitting in your log stream for the length of your retention period. I’ve written up the full structured-logging setup I run on this site, including the request ID that ties lines together and the rules that keep secrets out of them.
Two of those fields deserve a second look. ip and ua are what make a session record useful in an investigation – they’re also personal data in most jurisdictions I work in, and the ship’s-log framing is not a license to keep them forever. Decide the retention period for auth records deliberately and separately from your general log retention, write it down, and enforce it in the sink rather than hoping nobody queries the old partitions. A ledger has an archive policy; a firehose that never forgets is a liability with good grep support.
Treat the audit trail as append-only, because a ledger is append-only. You don’t go back and fix a watch entry from Tuesday. If a record was wrong, you write a correcting record – the original stays. This is the same discipline financial systems use for posted transactions, and it exists for the same reason: a record you can quietly rewrite has no evidentiary value. In practice that means these records stream out of the process to somewhere the application cannot edit, and removing old entries is a retention policy, not an UPDATE. Note the narrowing – this is a rule for the auth and audit records specifically, not a demand that every debug line your service emits be treated as evidence. Operational logs can be sampled, truncated, and dropped on the floor; the ledger can’t.
Log so that position is reconstructible. Dead reckoning works only if every leg of the journey is written down. The equivalent failure in software is logging that something happened without logging what it changed. password reset requested is a doorbell. password reset requested → token issued (expires 15m) → token consumed from a different IP → all sessions revoked is a course you can plot afterward. When you decide what to log, ask whether the line moves the system’s position or just announces that code executed.
Bill-shaped questions are audit-shaped questions. CTSS logged sessions to charge for machine time, and that turned out to produce exactly the records you’d want for an investigation. The overlap isn’t a coincidence – ‘who consumed what, when, for how long’ is one question with two use cases. If you’re already logging usage for metering or quotas, you’re most of the way to an auth trail, and if you’re logging auth properly you can usually answer the billing question for free.
The Rest of the Family
The wooden root sprouted more of your working vocabulary than you’d expect.
backlog started, in the 1680s, as the big log placed at the back of a fireplace – the slow-burning one that kept the fire going while the smaller stuff up front did the visible work. By 1883 it meant something stored up for later use, and by 1932 it meant arrears of unfulfilled orders. Your sprint backlog is a fire-tending metaphor: the reserve at the back, waiting to be burned.
blog is the fun one. Jorn Barger coined weblog in December 1997 for his site Robot Wisdom – literally logging the web, a running record of what he’d sailed past. In 1999 Peter Merholz split it in a sidebar as ‘we blog,’ the short form stuck, and Pyra Labs named their product Blogger. So this article, on a blog, about the word log, is itself named after a plank of wood thrown off the back of a boat.
logarithm is the impostor. John Napier coined it in the 1610s from Greek logos (ratio, proportion) plus arithmos (number) – ‘ratio-number.’ Nothing to do with timber. It’s the one log in your stack with a completely unrelated ancestry, which is why Math.log() and console.log() are false friends: same three letters, two thousand years and one ocean apart.
The Short Version
A word for a piece of wood, origin unknown. Tied to a rope, thrown off a stern to measure speed. The measurements went into a book, and the book took the instrument’s name. The book’s purpose was to reconstruct a position nobody could see directly. In 1963, a shared computer needed to know whose session was whose and how much time it had eaten, so it opened an entry and closed it with a total – and called the commands login and logout at a point when the password was still described as something that might be added later.
Your auth log inherits that job description. Not ‘prove someone was allowed in’ – that’s authentication, a different problem, solved by different code. The log’s job is to let someone reconstruct, after the fact, where the system has been. Close the entries you can observe closing, be explicit about the ones you can’t, and don’t rewrite Tuesday.
Further reading:
- Structured Logging in Next.js with Pino – the request-ID setup and secret-hygiene rules referenced above
- Idempotency Keys for API Retries – the other place where making a repeated write land exactly once is the whole design
- The Compatible Time-Sharing System: A Programmer’s Guide (MIT Press, 1963) – the
logincommand is on page 69, the sample session on page 91 - Chip log – the instrument, including the knot-spacing arithmetic
- etymonline: log – dates for log-book (1670s), the verb (1823), and the noun clipping (1842)








