Select platform: [Android](https://developers.google.com/maps/documentation/maps-3d/android-sdk/configure-marker-altitude.md.txt "View this page for the Android platform docs.") [iOS](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/configure-marker-altitude.md.txt "View this page for the iOS platform docs.")

<br />

You can customize the

altitude

of
markers that you add to a 3D map.

![Extruded marker on a 3D map](https://developers.google.com/static/maps/documentation/maps-3d/ios-sdk/images/extruded-markers.png)

The following code sample demonstrates how to set the altitude and altitude mode
of a [`Marker3D`](https://developers.google.com/maps/documentation/maps-3d/ios-sdk/reference/Structs/Marker3D.md.txt).

```swift
@State var extrudedMarker: Marker3D = .init(
  position: .init(
      latitude: 37.78980534,
      longitude:  -122.3969349,
      altitude: 50.0),
  altitudeMode: .relativeToGround,
  collisionBehavior: .required,
  extruded: true,
  drawsWhenOccluded: true,
  sizePreserved: true,
  zIndex: 0,
  label: "Extruded marker"
)
```