What is the "timestamp server" idea at the heart of a blockchain?
Publish a hash of each block of items; because each hash folds in the previous one, the blocks form a tamper-evident chain that fixes what existed and in what order — the shared ordering the network needs, with no central clock.
* Every block's hash folds in the previous block's hash — change one old item and its hash changes, breaking every link that came after. *
The job is to agree on what data existed and in what order — without trusting a clock or a central record-keeper. A timestamp server does it by taking a hash of a batch of items and publishing that hash widely (Nakamoto's analogy: printing it in a newspaper). The data had to exist to produce the hash, so the published hash proves it existed by that moment and can't be backdated.
The word timestamp is a little misleading: it isn't a precise wall-clock reading but proof-of-existence plus relative order — this block came after the one whose hash it carries. Folding each previous hash into the next builds a chain, so altering any old block changes its hash and breaks every link after it; the whole ordering is tamper-evident.
That shared ordering is exactly what the double-spending problem needed: once everyone agrees on one chain fixing the sequence of transactions, the network can treat the earliest spend of a coin as the valid one. The catch in this classic design is that someone still has to publish the hashes — a trusted party. Bitcoin's real contribution is replacing that publisher with proof-of-work, so the timestamping becomes distributed and permissionless.
Go deeper:
Trusted timestamping — Wikipedia — including "linking-based" schemes where each timestamp is chained to earlier ones, the pre-blockchain ancestor of this idea.