ID EN
OS Path

getctime

Python 3.11

Return the system’s ctime which, on some systems (like Unix) is the time of the last metadata change, and, on others (like Windows), is the creation time for path. The return value is a number giving the number of seconds since the epoch (see the time module). Raise OSError if the file does not exist or is inaccessible.

Syntax

PYTHON
os.path.getctime(path)

See Also

time OSError path-like object