---
title: "upToNextMajor(from:)"
framework: swift-package-manager
role: symbol
role_heading: Type Method
path: "swift-package-manager/documentation/packagedescription/swift/range/uptonextmajor(from:)"
---

# upToNextMajor(from:)

Returns a requirement for a version range, starting at the given minimum version and going up to the next major version. This is the recommended version requirement.

## Declaration

```swift
static func upToNextMajor(from version: Version) -> Range<Bound> where Bound == Version
```

## Parameters

- `version`: The minimum version for the version range.
