---
title: "createSymbolicLink(atPath:pathContent:)"
framework: foundation
role: symbol
role_heading: Instance Method
path: "foundation/filemanager/createsymboliclink(atpath:pathcontent:)"
---

# createSymbolicLink(atPath:pathContent:)

Creates a symbolic link identified by a given path that refers to a given location.

## Declaration

```swift
func createSymbolicLink(atPath path: String, pathContent otherpath: String) -> Bool
```

## Parameters

- `path`: The path for a symbolic link.
- `otherpath`: The path to which path should refer.

## Return Value

Return Value true if the operation is successful, otherwise false. Returns false if a file, directory, or symbolic link identical to path already exists.

## Discussion

Discussion Creates a symbolic link identified by path that refers to the location otherPath in the file system. Special Considerations Because this method does not return error information, it has been deprecated as of OS X v10.5. Use createSymbolicLink(atPath:withDestinationPath:) instead.

## See Also

### Related Documentation

- [removeItem(atPath:)](foundation/filemanager/removeitem(atpath:).md)
- [destinationOfSymbolicLink(atPath:)](foundation/filemanager/destinationofsymboliclink(atpath:).md)
- [createSymbolicLink(atPath:withDestinationPath:)](foundation/filemanager/createsymboliclink(atpath:withdestinationpath:).md)

### Deprecated Methods

- [changeFileAttributes(_:atPath:)](foundation/filemanager/changefileattributes(_:atpath:).md)
- [fileAttributes(atPath:traverseLink:)](foundation/filemanager/fileattributes(atpath:traverselink:).md)
- [fileSystemAttributes(atPath:)](foundation/filemanager/filesystemattributes(atpath:).md)
- [directoryContents(atPath:)](foundation/filemanager/directorycontents(atpath:).md)
- [createDirectory(atPath:attributes:)](foundation/filemanager/createdirectory(atpath:attributes:).md)
- [pathContentOfSymbolicLink(atPath:)](foundation/filemanager/pathcontentofsymboliclink(atpath:).md)
- [fileManager(_:shouldProceedAfterError:)](objectivec/nsobject-swift.class/filemanager(_:shouldproceedaftererror:).md)
- [fileManager(_:willProcessPath:)](objectivec/nsobject-swift.class/filemanager(_:willprocesspath:).md)
- [replaceItemAtURL(originalItemURL:withItemAtURL:backupItemName:options:)](foundation/filemanager/replaceitematurl(originalitemurl:withitematurl:backupitemname:options:).md)
