cal(1)
Display a calendar for a specified month or year.
Synopsis
cal [OPTION]... [MONTH] [YEAR]Description
cal displays a simple calendar. If no arguments are given, it shows the current month. You can specify a month and year to view any calendar. Months can be given as numbers (1–12) or full month names. Years should be given as four-digit numbers.
By default, cal highlights the current day (if viewing the current month). The output uses Sunday as the first day of the week by default, though this can be changed with options.
Common options
| Flag | What it does |
|---|---|
-m | Display the month with Monday as the first day of the week (instead of Sunday) |
-j | Show day numbers as day-of-year (Julian day) instead of day-of-month |
-y | Display a calendar for the entire year (12 months in a 3×4 grid) |
-3 | Show the previous month, current month, and next month in three columns |
-A NUM | Show NUM months after the specified month |
-B NUM | Show NUM months before the specified month |
-w | Print week numbers (ISO 8601) in the leftmost column |
--color=WHEN | Colorize output: auto (default), always, or never |
Examples
Display the calendar for the current month with today highlighted
calShow the entire year 2024 in a 12-month grid layout
cal 2024Display December 2024 calendar
cal 12 2024Show February, March, and April 2024 side by side
cal -3 March 2024Display current month with Monday as the first day of the week
cal -mShow June 2024 with day numbers as Julian days (day-of-year)
cal -j 6 2024Display 2024 calendar with ISO week numbers on the left
cal -w 2024Show November, December, January, February, and March
cal -B 2 -A 2 January