The Catechism of the Catholic Church explains holy days of obligation this way:
On Sundays and other holy days of obligation, the faithful are to refrain from engaging in work or activities that hinder the worship owed to God, the joy proper to the Lord’s Day, the performance of the works of mercy, and the appropriate relaxation of mind and body.
Family needs or important social service can legitimately excuse from the obligation of Sunday rest.
The faithful should see to it that legitimate excuses do not lead to habits prejudicial to religion, family life, and health [CCC 2185].
The Code of Canon Law spells out when the holy days of obligation are on the Church’s universal calendar:
Can. 1246 §1. Sunday, on which by apostolic tradition the paschal mystery is celebrated, must be observed in the universal Church as the primordial holy day of obligation. The following days must also be observed:
These ten are the exact holy days of obligation that are celebrated in Vatican City, but there is variation elsewhere (including in Italy). The reason is that the Code of Canon Law goes on to state:
Thus different countries celebrate different holy days of obligation (apart from Sunday, which they all celebrate).
The country with the fewest number of holy days of obligation seems to Hong Kong, which has only one: Christmas.
Canada has two: Christmas and Mary, Mother of God.
The United States, by contrast, has a fairly robust eight holy days of obligation, though two to three have been transferred to Sundays (depending on where you live).
The details of how the holy days in the U.S. have evolved are found here.
The details can be a little bewildering though, so here is a complete, up-to-date list of the holy days of obligation in the United States:
There is one other wrinkle to the holy days of obligation in the United States: the state of Hawaii.
Hawaii is part of the United States, but it is located in a part of the world where most of the surrounding dioceses belong to the Conference of Bishops of the South Pacific (CEPAC).
As a result, there is a special indult for Hawaii to regulate its liturgical days in accord with the surrounding dioceses. Therefore, since 1992, Hawaii has only had two holy days of obligation (besides Sundays), which are the Immaculate Concept (Dec. 8) and Christmas (Dec. 25).