---
title: "initialFrame(for:)"
framework: uikit
role: symbol
role_heading: Instance Method
path: "uikit/uiviewcontrollercontexttransitioning/initialframe(for:)"
---

# initialFrame(for:)

Returns the starting frame rectangle for the specified view controller’s view.

## Declaration

```swift
func initialFrame(for vc: UIViewController) -> CGRect
```

## Parameters

- `vc`: The view controller whose frame rectangle you want.

## Return Value

Return Value The frame rectangle for the view or CGRectZero if the frame rectangle is not known or the view is not visible.

## Discussion

Discussion The rectangle returned by this method represents the size of the corresponding view at the beginning of the transition. For the view controller that is already onscreen, this rectangle typically matches the frame rectangle of the container view. For the view controller being presented, the value returned by this method is typically CGRectZero because the view is not yet on screen.

## See Also

### Getting the transition frame rectangles

- [finalFrame(for:)](uikit/uiviewcontrollercontexttransitioning/finalframe(for:).md)
