Skip to main content
`Ctrl`+`K`

# pandas.PeriodIndex.month

property PeriodIndex.month

  The month as January=1, December=12.

  Returns the month component for each period in the index as an integer, where January is 1 and December is 12.

  See also

  `PeriodIndex.days_in_month`

    The number of days in the month.

  `PeriodIndex.daysinmonth`

    The number of days in the month.

  Examples

      >>> idx = pd.PeriodIndex(["2023-01", "2023-02", "2023-03"], freq="M")
      >>> idx.month
      Index([1, 2, 3], dtype='int64')