Worth pointing out that sometimes a block will have a timestamp that is earlier than the previous block.
This is because:
A timestamp is accepted as valid if it is greater than the median timestamp of previous 11 blocks, and less than the network-adjusted time + 2 hours. "Network-adjusted time" is the median of the timestamps returned by all nodes connected to you
In Bitcoin the main concept of time is block height, not timestamps. Every milestone in the network(halving, difficulty adjustment, etc) is defined by this, not by the time we normally use, which is just an approximation.
Also worth noting that devices that use the unix timestamp as signed integers will have issues in the year 2038, but Bitcoin uses unsigned ints for this, so it will be an issue in the year 2106 instead. More details about this here. Note that this will happen before the last mining reward is sent, which will happen approximately in the year 2140.