# Align and Position the .NET MAUI BadgeView

The BadgeView provides properties for setting the alignment and position of the Badge indicator based on the BadgeView `Content`.

## Positioning the Badge

To specify the position of the Badge according to its content, use the following properties:

* `BadgeHorizontalPosition`(of type `Telerik.Maui.Controls.BadgeView.BadgePosition`)—Specifies the horizontal `BadgePosition` of the Badge. The supported options are: `Start`, `Center`, `End`. The default value is `End`.

  ![Telerik UI for .NET MAUI BadgeView demonstrating Start, Center, and End horizontal badge positions](https://www.telerik.com/maui-ui/documentation/assets/afe13df8444233b7cc932584218df7c9/badgeview-horizontal-position.png)

* `BadgeVerticalPosition`(of type `Telerik.Maui.Controls.BadgeView.BadgePosition`)—Specifies the vertical `BadgePosition` of the Badge. The supported options are: `Start`, `Center`, `End`. The default value is `Start`.

  ![Telerik UI for .NET MAUI BadgeView demonstrating Start, Center, and End vertical badge positions](https://www.telerik.com/maui-ui/documentation/assets/8c218e0dd2fc7efcd489904b1c53fd77/badgeview-vertical-position.png)

## Aligning the Badge

To specify the alignment of the Badge according to its content, use the following properties:

* `BadgeHorizontalAlignment`(of type `Telerik.Maui.Controls.BadgeView.BadgeAlignment`)—Specifies the horizontal alignment of the badge. The supported options are: `Start`, `Center`, `End`. The default value is `Center`.

  ![Telerik UI for .NET MAUI BadgeView demonstrating Start, Center, and End horizontal badge alignment](https://www.telerik.com/maui-ui/documentation/assets/730c462c81f5108874d0571eead2ec9a/badgeview-horizontal-alignment.png)

* `BadgeVerticalAlignment`(of type `Telerik.Maui.Controls.BadgeView.BadgeAlignment`)—Specifies the vertical alignment of the Badge. The supported options are: `Start`, `Center`, `End`. The default value is `End`.

  ![Telerik UI for .NET MAUI BadgeView demonstrating Start, Center, and End vertical badge alignment](https://www.telerik.com/maui-ui/documentation/assets/8a3c5dba102eb8bbc0d07c60918a5e45/badgeview-vertical-alignment.png)

## Offset

You can also specify the horizontal and vertical distance between the content of the Badge indicator and its alignment point by using the following properties:

* `BadgeOffsetX`(`double`)—Specifies the horizontal distance between the content of the Badge and its alignment point. The default value is `0`.

* `BadgeOffsetY`(`double`)—Specifies the vertical distance between the content of the Badge and its alignment point. The default value is `0`.

## Example

The following example demonstrates how to position and align the Badge as well as set its offset.

```XAML
<telerik:RadBadgeView BadgeText="12"
                                BadgeVerticalPosition="End"
                                BadgeHorizontalAlignment="End"
                                BadgeOffsetX="-5"
                                VerticalOptions="Center">
    <telerik:RadBadgeView.Content>
        <telerik:RadButton Padding="15, 10, 15, 10"
                           CornerRadius="20"
                           Text="Shopping Cart"
                           TextColor="White"
                           VerticalOptions="Center"
                           VerticalContentAlignment="Center"
                           BackgroundColor="#0E88F2"/>
    </telerik:RadBadgeView.Content>
</telerik:RadBadgeView>
```

The following image shows the final result.

![Telerik UI for .NET MAUI BadgeView with a Shopping Cart button and notification badge positioned and aligned on the right](https://www.telerik.com/maui-ui/documentation/assets/543edb3b1b77c88aa658e9c8ed001b96/badgeview-position-alignment.png)

## See Also

* [Badge Animation](https://www.telerik.com/maui-ui/documentation/controls/badgeview/animation)
* [Predefined Badges](https://www.telerik.com/maui-ui/documentation/controls/badgeview/predefined-badges)
