Canon 1247. On Sundays and other holy days of obligation, the faithful are obliged to participate in the Mass. Moreover, they are to abstain from those works and affairs which hinder the worship to be rendered to God, the joy proper to the Lord’s day, or the suitable relaxation of mind and body.
Canon 1248 §1. A person who assists at a Mass celebrated anywhere in a Catholic rite either on the feast day itself or in the evening of the preceding day satisfies the obligation of participating in the Mass.
The liturgy allowed during the time that satisfies the Sunday obligation may be restricted by the bishop or bishop’s conference, but sometimes it is not restricted. It is an obligation to go to Mass within the Sunday time frame described…
…and because not everyone can go to Mass on Sunday, there are recorded Masses broadcast for reasons of edification, whether people can personally attend Sunday Mass or not:
Canon 1248 §2. If participation in the eucharistic celebration becomes impossible because of the absence of a sacred minister or for another grave cause, it is strongly recommended that the faithful take part in a liturgy of the word if such a liturgy is celebrated in a parish church or other sacred place according to the prescripts of the diocesan bishop or that they devote themselves to prayer for a suitable time alone, as a family, or, as the occasion permits, in groups of families.