<!--
{
  "documentType" : "article",
  "framework" : "TVML",
  "identifier" : "/documentation/TVML/heroimg",
  "metadataVersion" : "0.1.0",
  "role" : "collectionGroup",
  "title" : "heroImg"
}
-->

# heroImg

Displays an image that is usually large and detailed.

## Overview

The `heroImg` element contains a link to an image that is to be displayed. This element
is commonly used to display a picture of a product inside of a banner. Here’s an
example of a `heroImg` element used to promote a movie.

```xml
<heroImg src="path to images on your server/Car_Movie_720x1080.png" />
```

### Contained In

- [background](/documentation/TVML/background)
- [banner](/documentation/TVML/banner)
- [itemBanner](/documentation/TVML/itembanner)
- [placeholder](/documentation/TVML/placeholder)

## Topics

### Valid TVML Styles

[border-radius](/documentation/TVML/border-radius)

Changes the shape of an element’s corner.

[height](/documentation/TVML/element-shaping-height)

Specifies the height of an element.

[margin](/documentation/TVML/margin)

Specifies the spacing around an element.

[width](/documentation/TVML/element-shaping-width)

Specifies how wide an element is.

### Valid TVML Attributes

[accessibilityText](/documentation/TVML/accessibilitytext)

Adds hidden text to an element that is used when VoiceOver is enabled.

[binding](/documentation/TVML/binding)

Associates information in a data item with an element.

[contentsMode](/documentation/TVML/contentsmode)

Specifies how an image is expanded to fill its containing element.

[height](/documentation/TVML/image-attributes-height)

Specifies the maximum height for an image.

[opaque](/documentation/TVML/opaque)

Indicates whether an image has a transparent background.

[prototype](/documentation/TVML/prototype)

Associates a data item type with an element.

[src](/documentation/TVML/src)

Specifies the URL for an image.

[srcset](/documentation/TVML/srcset)

Specifies multiple URLs for an image.

[width](/documentation/TVML/image-attributes-width)

Specifies the maximum width for an image element.

[theme](/documentation/TVML/theme)

Sets the color scheme for an element.



---

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)