<!--
{
  "documentType" : "article",
  "framework" : "Xcode",
  "identifier" : "/documentation/Xcode/swift-packages",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "Swift packages"
}
-->

# Swift packages

Create reusable code, organize it in a lightweight way, and share it across Xcode projects and with other developers.

## Overview

![An image illustrating how Xcode supports bundling code, resources, and binaries into a Swift package.](images/com.apple.Xcode/swift-packages~dark@2x.png)

Swift packages are reusable components of Swift, Objective-C, Objective-C++, C, or C++ code that developers can use in their projects. They bundle source files, binaries, and resources in a way that’s easy to use in your app’s project.

Xcode supports creating and publishing Swift packages, as well as adding, removing, and managing package dependencies. Its support for Swift packages is built on top of the open source Swift Package Manager project.

To learn more about the API you use in your package manifest, see <doc://com.apple.documentation/documentation/PackageDescription/Package>. To learn more about the Swift Package Manager, see [Swift.org](https://swift.org/package-manager/) and the open source [Swift Package Manager repository](https://github.com/apple/swift-package-manager).

## Topics

### Package dependencies

[Adding package dependencies to your app](/documentation/Xcode/adding-package-dependencies-to-your-app)

Integrate package dependencies to share code between projects, or leverage code from other developers.

[Identifying binary dependencies](/documentation/Xcode/identifying-binary-dependencies)

Find out if a package dependency references a binary and verify the binary’s authenticity.

[Editing a package dependency as a local package](/documentation/Xcode/editing-a-package-dependency-as-a-local-package)

Override a package dependency and edit its content by adding it as a local package.

### Package creation

[Creating a standalone Swift package with Xcode](/documentation/Xcode/creating-a-standalone-swift-package-with-xcode)

Bundle executable or shareable code into a standalone Swift package.

[Bundling resources with a Swift package](/documentation/Xcode/bundling-resources-with-a-swift-package)

Add resource files to your Swift package and access them in your code.

[Localizing package resources](/documentation/Xcode/localizing-package-resources)

Ensure that your Swift package provides localized resources for many locales.

[Distributing binary frameworks as Swift packages](/documentation/Xcode/distributing-binary-frameworks-as-swift-packages)

Make binaries available to other developers by creating Swift packages that include
one or more XCFrameworks.

[Developing a Swift package in tandem with an app](/documentation/Xcode/developing-a-swift-package-in-tandem-with-an-app)

Add your published Swift package as a local package to your app’s project and develop
the package and the app in tandem.

[Organizing your code with local packages](/documentation/Xcode/organizing-your-code-with-local-packages)

Simplify maintenance, promote modularity, and encourage reuse by organizing your
app’s code into local Swift packages.

  <doc://com.apple.documentation/documentation/PackageDescription>

### Package distribution

[Publishing a Swift package with Xcode](/documentation/Xcode/publishing-a-swift-package-with-xcode)

Publish your Swift package privately, or share it globally with other developers.

### Continuous integration

[Building Swift packages or apps that use them in continuous integration workflows](/documentation/Xcode/building-swift-packages-or-apps-that-use-them-in-continuous-integration-workflows)

Build Swift packages with an existing continuous integration setup and prepare apps
that consume package dependencies within an existing CI pipeline.



---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)
