<!--
{
  "availability" : [
    "iOS: 7.0.0 -",
    "iPadOS: 7.0.0 -",
    "macCatalyst: 14.0.0 -",
    "macOS: 10.15.0 -",
    "tvOS: 17.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "AVFoundation",
  "identifier" : "/documentation/AVFoundation/AVCaptureVideoDataOutput/recommendedVideoSettingsForAssetWriter(writingTo:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "AVFoundation"
    ],
    "preciseIdentifier" : "c:objc(cs)AVCaptureVideoDataOutput(im)recommendedVideoSettingsForAssetWriterWithOutputFileType:"
  },
  "title" : "recommendedVideoSettingsForAssetWriter(writingTo:)"
}
-->

# recommendedVideoSettingsForAssetWriter(writingTo:)

Specifies the recommended settings for use with an AVAssetWriterInput.

```
func recommendedVideoSettingsForAssetWriter(writingTo outputFileType: AVFileType) -> [String : Any]?
```

## Parameters

`outputFileType`

The Uniform Type Identifier of the file type to write. See `File Format UTIs` for supported types.

## Return Value

A fully populated dictionary of keys and values that are compatible with [`AVAssetWriter`](/documentation/AVFoundation/AVAssetWriter).

## Discussion

This dictionary contains keys and values described in [Video settings](/documentation/AVFoundation/video-settings) and is suitable for use when creating an [`AVAssetWriterInput`](/documentation/AVFoundation/AVAssetWriterInput) with the [`init(mediaType:outputSettings:)`](/documentation/AVFoundation/AVAssetWriterInput/init(mediaType:outputSettings:)) initializer. For QuickTime movie and ISO file types, the recommended video settings produce output comparable to that of [`AVCaptureMovieFileOutput`](/documentation/AVFoundation/AVCaptureMovieFileOutput).

Note that the dictionary of settings is dependent on the current configuration of the output’s [`AVCaptureSession`](/documentation/AVFoundation/AVCaptureSession) and its inputs. The settings dictionary may change if the session’s configuration changes. As such, configure your session first, then query the recommended video settings.

> Note:
> This method returns appropriate settings based on the device’s default video recording codec, but that default can differ between devices. Use the ``doc://com.apple.avfoundation/documentation/AVFoundation/AVCaptureVideoDataOutput/recommendedVideoSettings(forVideoCodecType:assetWriterOutputFileType:)`` method to obtain video settings appropriate for a specific codec.

---

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)