Chinese kinship
The Chinese kinship system (simplified Chinese: 亲属系统; traditional Chinese: 親屬系統; pinyin: qīnshǔ xìtǒng) is among the most complicated of all the world's kinship systems. It maintains a specific  designation for almost every member's kin based on their generation, lineage, relative age, and gender. The traditional system was agnatic. based on patriarchal power, patrilocal residence, and descent through the male line. Although there has been much change in China over the last century, especially after 1949, there has also been substantial continuity.In the extended family, every child, from birth, participated in an organized system of kinship relations involving elder brothers, sisters, maternal elder brothers' wives, and various aunts, uncles, cousins, grandparents, and in-laws.
The Chinese kinship system (simplified Chinese: 亲属系统; traditional Chinese: 親屬系統; pinyin: qīnshǔ xìtǒng) is among the most complicated of all the world's kinship systems. It maintains a specific  designation for almost every member's kin based on their generation, lineage, relative age, and gender. The traditional system was agnatic. based on patriarchal power, patrilocal residence, and descent through the male line. Although there has been much change in China over the last century, especially after 1949, there has also been substantial continuity.In the extended family, every child, from birth, participated in an organized system of kinship relations involving elder brothers, sisters, maternal elder brothers' wives, and various aunts, uncles, cousins, grandparents, and in-laws. These relationships were precisely named and differentiated and carried rights and duties. Family members anticipated being addressed by the correct term that indicated their relationship to the person communicating with them.In the Chinese kinship system:

Maternal and paternal lineages are distinguished. For example, a mother's brother and a father's brother have different terms.
The relative age of a sibling is indicated by specific terms. For example, a father's younger brother has a different terminology than his older brother.
The gender of the relative is distinguished, as in English.
The generation from ego is indicated, like in English.The 19th century anthropologist Lewis Henry Morgan, without field-work or detailed descriptions, classified Chinese kinship as a "Sudanese" or "descriptive" system.

Kinship and Chinese societies
Literature and history
Kinship terms appeared in the earliest Chinese lexicon, Erya. Chapter Four Shiqin (释亲/釋親) is dedicated to an explanation of kinship and marriage. Another lexicon from the late Han dynasty, Shiming, has a detailed list of forms of address for all relatives.
With the influence of Confucianism, the concepts of kinship and consanguinity are deeply ingrained in Chinese culture. One of the Confucian teachings is filial piety, which it is extended to a series of five relationships known as the Five Cardinal Relationships (五倫), three of which are related to the family:

ruler and subject (君臣 Pinyin: jūnchén)
father and son (父子 fùzǐ)
elder and younger brother (兄弟 xiōngdì)
husband and wife (夫婦 fūfù)
between friends (朋友 péngyǒu)In the Three Character Classic, the nine agnates are listed in the following stanza:

Culture
In Chinese culture where the extended family is still valued, kinship terms have survived well into current usage. Also, since it is taboo to refer to or address a more senior family relation by his or her given name, the kinship term is the only possible term of address. When there are many siblings as in many Post–World War II baby-boom families, the relation is distinguished and addressed according to age or rank. For example, 大 (great/senior/elder) is used in the address for 大姨 (the eldest sister of one's mother); 二姨 for the second eldest sister of one's mother; 三姨 for the third eldest sister of one's mother, etc.  In cases where someone is older than his more senior relation, such as an uncle, it is common to address the senior relation with a diminutive suffix.
Because some of these terms have no equivalent in foreign languages, they are not easily translated and the descriptiveness is often lost in translation. However, terms such as "Second Uncle" are sometimes used.  Translating kinship terms from other languages often presents the problem of ambiguity as there is no equivalent general term such as "aunt".
Despite the complexity of the kinship address system (see terminology section below), it is common to simplify it for the sake of familiarity. Some formal kinship terms are not familiar to many people, cumbersome, or not preferred by the addressee. For example, a cousin once removed may at her discretion be referred to as simply a cousin if she is of a similar age to the speaker.

Law
The Great Qing Legal Code (大清律例) was the last set of Chinese laws where the complete kinship terms were shown. The Qing code not only confirmed the importance of defining kinship relations, but also defined the legal and moral conducts between family relations. Although there was no specific statute in the Qing code to define kinship terms, it specified the mourning attire and ritual appropriate according to the relation between the mourner and the deceased. Kinship relationships also played a crucial role in the administration of justice under the Qing. Penalties were more severe for crimes committed against senior relatives within the family hierarchy. Crimes committed against those outside of the extended family were punished less harshly. Crimes committed by senior family members against their inferiors were least likely to elicit harsh sentences.
Among the 47 statutes added in 1740 under Qianlong Emperor, Statute 2 (Charts/Tables of Mourning Attire, (喪服諸圖)) and Statute 3 (Code of Attire, (服制)) dealt with mourning attire completed with charts. According to Qing law, one had to observe a period of mourning when a relative died. The closer and more senior the deceased family member, the longer the period of mourning is dictated by law. The mourning period range from three months to three years. During this period, the bereaved had to stay at home, excuse himself from public service, refrain from celebrations of all sorts, and practice abstinence, among other things.
The "extermination of nine kindreds" (誅九族) is considered one of the most severe punishments found in traditional Chinese law enforced until the end of Qing. The practice of exterminating the kins had been established since Qin when Emperor Qin Shi Huang (reigned 247 BC–221 BC) declared "Those who criticize the present with that of the past, Zu" (以古非今者族). Zu (族) referred to the "extermination of three kindreds" (三族): father, son and grandson. The extermination was to ensure the elimination of challenges to the throne and political enemies. Emperor Wen of Sui (reigned 581–604) abolished the practice but it was reintroduced by the succeeding Emperor Yang (reigned 604–617). Not only did he bring back the punishment, but he also extended it to the nine kindreds.
In the first year of the reign of the Yongle Emperor (Ming dynasty, reigned 1402–1424), the prominent historian Fāng Xìao-rú (方孝孺) committed an offense worthy of the "extermination of nine kindreds" for refusing to write the inaugural address and for insulting the Emperor. He was recorded as saying in defiance to the would-be Emperor: "莫說九族，十族何妨！" ("Never mind nine agnates, go ahead with ten!"). Thus he was granted his wish with an infamous case, perhaps the only one, of "extermination of ten kindreds" (誅十族) in the history of China. In addition to the blood relations from his nine-agnates family hierarchy, his students and peers were added to be the tenth group. Altogether 873 people were said to have been executed.
To this day, a three-character term (冚家鏟) for "death to the entire family" remains a powerful swear in the Cantonese language.

Clan
A Chinese clan is a patrilineal and patrilocal group of related Chinese people with a common surname sharing a common ancestor. In southern China, clan members could form a village known as an ancestral village. In Hong Kong, clan settlement is exemplified by walled villages. An ancestral village usually features a hall and shrine honoring ancestral clan members. A clan pedigree can be found recording male members of the clan. A married woman is considered part of her husband's clan.

Marriage and divorce
Marriage is an important rite signifying the coming together of two clans and the beginning of a new family unit. Marriage has to be permanent and issue is expected. Weddings were central occasions in a family's life. Spouses were chosen carefully by the parents. Marital agreements, especially among the well-to-do, were stipulated with contracts between both families. This practice was continued for centuries and spread throughout the world, and goes on to this day. Divorce was nearly impossible. The choices made between the families held great importance weddings were held on certain days to ensure good fortune. This practice gained prominence during the Han dynasty (202BCE-220CE).

Polygamy
Polygamy (specifically polygyny) had been practiced in Chinese societies for thousands of years. Since the Han dynasty, Chinese men have been able to legally have only one wife. It was common for privileged Chinese men to have a wife and various concubines, however. For those who could afford a bride price and support a family of multiple concubines and children, polygyny provided a better chance of issuing heirs. The importance of this was apparent in the imperial court, which usually housed hundreds of concubines. Aside from concubinage, having multiple wives with equal status was also accepted prior to the ban on polygamy.
In a concubinage situation, the wife, concubines and their children would live in the same household. Wives and concubines would often refer to each other as "sisters". As a concubine was not wedded in a marriage ceremony, she had fewer rights in the household. There was also no inter-clan relation between the man's clan and the concubine's own kin.
Polygamy was banned in China in 1930 when the Republic of China government promulgated Civil Code (Part IV) where Section 985 states "A person who has a spouse may not contract another marriage. A person shall not marry with two or more persons simultaneously." This is still in effect today in the territories under effective administration of the Republic of China including Taiwan and Kinmen and Matsu. However, as infringement of marriage cannot be prosecuted without a complaint by the wife, one can still unofficially practice polygamy by registering only one marriage. Such practice still happen occasionally among older and wealthy men. After the establishment of the People's Republic of China by the Chinese Communists on the mainland, this banning was reaffirmed in the passage of the Marriage Code of 1950. In Hong Kong, new polygamous marriages were no longer legally allowed after 1971 with the passage of the Marriage Reform Ordinance (Cap. 178). Due to this, incidents of extramarital affairs are rising. Some men have even established a family with their mistresses and children kept secret from their wives. There is a phenomenon of cross-border polygyny usually involving Hong Kong men and their mistresses living in Mainland China.

Demographics
With modern Chinese governments advocating smaller families through family planning campaigns and policy-making, large extended families may be a thing of the past. The People's Republic of China introduced its One-child policy in 1979, and The Family Planning Association of Hong Kong began its "Two is enough!" (兩個就夠哂數!) campaign in the 1970s. Contrasted with the large extended families created during the pre-war and baby-boom years, average modern Chinese families now have many fewer children.As of 2006, the fertility rates in Hong Kong and Macau ranked among the lowest two in the world. Hong Kong, ranked the lowest in the world, was the only territory with less than one child born per woman on the average. Both Mainland China and Taiwan were ranked well below the world average. Similarly, the birth rates in Hong Kong and Macau ranked among the lowest three in the world. Both Mainland China and Taiwan were ranked below the median.A product of rising divorce rates in Chinese societies is the breakdown of the traditionally close-knit kinship relation. On the other hand, remarriage could provide more than two sets of paternal or maternal relatives.

Defining kin
Nine grades of relations
The "nine grades of relations" (九族) is an important concept when it comes to application of laws and observing rituals. Since the Han dynasty, there have been two separate interpretations of what is defined by the nine grades. Each interpretation is based on societal and political needs as the ruler of the day see fit.
The "older" interpretation ("古文說") defined the nine grades of relations strictly in the paternal line. That is, nine generations from great-great-grandfather down to great-great-grandchildren. This interpretation was officially recognized after Tang and Song dynasties. By Ming and Qing dynasties, laws have defined the patrilineality of the nine kindreds. This interpretation was cited in Part III Chapter 2 of Lewis Henry Morgan's 1877 book Ancient Societies.
The "contemporary" interpretation ("今文說") defines the nine grades of relations to be four generations from the paternal line, three from the maternal line, and two from the wife's. Historically, this definition has been used during award, punishment and family annihilation.
Yet another interpretation suggests that "nine" is actually an arbitrary number as nine is considered a large number in Chinese culture. As such, it means anyone and everyone related is to be executed in the context of family annihilation.

Five degrees of mourning attire
The five degrees of mourning attire (五服) define not only the proper attire, but also the proper mourning ritual one should observe when a relative has died. Appearing in writings as early as the Rites of Zhou, mourning rituals developed over the years. By the time of the Qing dynasty, it was set down in law that there were five degrees, or grades of mourning according to the relationship one has with the deceased. The closer a person is related to the deceased, the higher the degree of mourning that is observed. A married female belongs to her husband's clan and observes a similar but lower degree of mourning than her husband. She would observe mourning for a small portion of the members from her own clan. A married man would observe mourning for an even smaller number of relatives of his in-laws.
In a concubinage situation, a concubine was only required to mourn for her husband, his wife, his parents, and all his children including her own, whereas a wife was required to mourn for almost all of her husband's near relatives. In addition, there was no requirement to mourn the death of a concubine except by the man's children.
Since the end of feudal China, the rituals of the five degrees of mourning have largely given way to simpler and less elaborate observance.
Conventionally, clans adopted the five degrees of mourning according to unwritten definitions that determines the difference between close and distant relatives. As such, marriage between relatives that were covered within the five degrees of mourning was considered taboo and immoral. These definitions, unlike the mourning ritual, are still applicable in determining whether a marriage is acceptable, albeit fewer people are familiar with the mourning rituals themselves.
According to these definitions, many relatives considered "distant" in Western cultures are considered close in Chinese culture.
The five degrees of mourning attire in decreasing order of severity are:

1. 斬榱 - 3 years (actually 25 months)
2. 齊榱 - 3 years, 1 year, 1 year with staff of mourning, 5 months, 3 months
3. 大功 - 9 months, 7 months
4. 小功 - 5 months
5. 緦麻 - 3 months

Common extended family and terminology
This section covers members and their spouses in the immediate and extended family that is commonly found in the first nine corner cells on the table of consanguinity or cousin chart (from ego to grandparents on the rows and columns). The terms are listed in Standard Chinese, regional and dialectal usages are listed in the corresponding row. The degrees of mourning attire are included as an indication of how close the relation is to ego and what level of respect is expected. "1" being the highest; "5" being the lowest. "0" means they are not within the definition of the five degrees of mourning. Some of these are common relations and are included for completeness. The degrees of mourning indicated in the table are based on ego as an unmarried member of the family.

General prefixes
外 (wài) - prefix to indicate maternal lineage on some of the relations
堂 (táng) - cousin: used in relation to descendants of father's brother
表 (biǎo) - other cousins: used in relation to descendants of father's sister and both mother's brother and sister
高 (gāo) - prefix for relations four generations removed senior of ego, i.e.: great-great-grandparents (高祖父母)
曾 (zēng) - prefix for relations three generations removed, i.e.: great-grandparents; great-grandchildren (曾祖父母; 曾孫)
祖 (zǔ) - prefix for relations two generations removed senior of ego, i.e.: grandparents (祖父母), also a general prefix for relations two or more generations senior of ego.
孫 (SC: 孙) (sūn) - prefix for relations two generations removed junior of ego, i.e.: grandchildren (孫), also a general prefix for relations two or more generations junior of ego.
玄/元 (xuán/yuán) - prefix for relations four generations removed junior of ego, i.e.: great-great-grandchildren (玄孫/元孫)Where they differ, the Simplified Chinese character is presented first, followed by the Traditional Chinese character in parentheses.

Members of the nuclear family
As with all languages, there exist a high degree of regional variation in kinship terminology. Different Chinese languages, dialects, and even families can have distinct words and pronunciations for the same person. In the tables below, the "other variants" presented happens to be mostly from Cantonese, and should not be interpreted as being comprehensive. Also, a person may use terminology from a region but pronounce the term with the regional pronunciation, a different regional pronunciation, or in Putonghua, which may be the case when a person has family members from different parts of China.

Members of the extended family
Larger extended family and terminology
This section covers members and their spouses found beyond the first nine corner cells on the table of consanguinity or cousin chart. Although some of the relations seem distant, they are considered close relatives and it is common for Chinese families to have regular contact with these members.

Distant relations
Other than some of the relations mentioned in the previous sections that are not covered under the five degrees of mourning attire, the following are kin that are also considered distant. 

(外)來孫 - great-great-great-grandchildren
(外)晜孫 - great-great-great-great-grandchildren
(外)仍孫 - great-great-great-great-great-grandchildren
(外)雲孫 - great-great-great-great-great-great-grandchildren
(外)耳孫 - great-great-great-great-great-great-great-grandchildren外 - prefix for maternal line relations; essentially anyone not sharing the same surname as ego

Partial or no consanguinity
The following familial relationship suggests partial or no consanguinity. Most of them are not a modern phenomenon, however. In fact, polygamy (specifically polygyny) was widely accepted in pre-republican China.
The saying of "three fathers and eight mothers" (三父八母) refers to:

Cohabiting stepfather (同居的繼父)
Non-cohabiting stepfather (不同居的繼父)
Stepfather from remarriage of father and mother (從父母嫁之繼父)
嫡母 - father's official wife (when birth mother of ego is a concubine)
繼母 - stepmother
養母 - adopted mother
慈母 - concubine replacing ego's birth mother who died
嫁母 - widowed birth mother who has remarried
出母 - birth mother who has been divorced
庶母 - father's concubine who is also a mother (when birth mother of ego is the official wife)
乳母 - wet nurseAnother saying of "five fathers and ten mothers" (五父十母) refers to

生父 - birth father
養父 - adopted father
繼父 - stepfather
義父 - godfather
師父 - (male) teacher/coach/masterand two mothers added to the eight mentioned above:

生母 - birth mother
諸母 - father's concubineAs a result of polygamy there would be half-siblings:

同父異母兄弟姐妹 - siblings sharing the same father
同母異父兄弟姐妹 - siblings sharing the same mother

See also
Chinese marriage
Chinese surname
Chinese compound surname
Chinese given name
Little Emperor SyndromeGeneral:

Family
Consanguinity
Patrilineality

Notes
References and further reading
Jankowiak, William; Sun, Yuezhu (8 June 2017). "Family Relationships in Contemporary China". Oxford Bibliographies.
Morgan, Lewis Henry. 1877. Ancient Society. MacMillan & Company, London (complete text online)
Watson, James L (1982). "Chinese Kinship Reconsidered: Anthropological Perspectives on Historical Research". The China Quarterly. 92: 589–622.
Wolf, Arthur P. and Chieh-shan Huang.  1985. Marriage and Adoption in China, 1845-1945.  Stanford University Press.
(in Chinese) Code of (Mourning) Attire tables
http://extremeorient.revues.org/234 The Father-Son Relationship in Early Medieval China