NTFS においてシンボリックリンクやらハードリンクやらはリパースポイントという機能で実装されています。 パスがリパースポイントかどうか判別する from ctypes import * FILE_ATTRIBUTE_REPARSE_POINT = 0x00000400 kernel = windll.kernel32 GetFileAttributes = kernel.GetFileAttributesW GetFileAttributes.argtypes = [c_wchar_p] def islink(path): attributes = GetFileAttributes(path) return attributes != -1 and bool(attributes & FILE_ATTRIBUTE_REPARSE_POINT) リンク先を取得する from os.pat