There are 7 days in a week, which I read was first devised by the Babylonians and carried forward to Europe. Some Roman calendars had 8 days, but at some point 7 prevailed and became the standard.
However, unlike a monthly calendar based on the moon or sun, it’s completely arbitrary that today is Tuesday rather than Friday. So at some point in history, someone(s) had to decide that today would a particular day rather than another day, and it was carried forward from there.
When was this decided and by whom? How far back can we confidently say that any multiple of 7 “days ago” was also a Tuesday?
There's an answer in the FAQ by u/yodatsracist that talks about this: When was it decided which day of the week it was, in order for today to be Wednesday?
It's a bit old now though so someone might be able to provide a new answer, as there's always more that can be said.