With the advancement of medical technology, liver cancer is no longer a terminal disease, but the exact number of years of life expectancy is influenced by multiple factors and cannot be generalized. There are some types of hepatocellular carcinoma that can have a clear better prognosis, with hepatocellular carcinoma less than 5 cm, which can be operated early. The cancer has an intact envelope, high degree of differentiation and no cancer thrombus formation yet. The immune status of the organism is good. Those who conform to these three, generally have good prognosis and have little impact on life expectancy. The factors that have a negative impact on the prognosis of liver cancer are as follows: stage of liver cancer: the stage of liver cancer means the metastasis situation, and TNM stage is commonly used in clinical practice. Since the early symptoms of liver cancer are not obvious, many patients are not early when they are discovered, which has formed the misconception that liver cancer is a terminal disease, but in fact, if detected early through regular medical checkups, there are still many treatment opportunities. Cooperation with treatment: Treatment of liver cancer is a long-term process, which requires repeated review and follow-up, and radiotherapy is painful. If patients can adhere to orthodox treatment, there is a great hope to prolong their life span, but if they cannot adhere to it, or if they are suspicious and resist, or believe in biased methods, they will often delay the disease and the treatment effect will be greatly reduced. Patients’ mentality: Cancer treatment will bring great psychological pressure to patients, so patients need to maintain a positive and optimistic mentality, and patients themselves and their family members should pay attention to guidance, if the mentality is positive, the treatment effect is often better, on the contrary, if patients have a negative mentality, the effect is often poor. In addition, patients’ physical and economic conditions can affect the treatment of cancer, so I will not enumerate them all. In summary, the life expectancy of liver cancer patients is affected by many factors, so it is difficult to make a generalization, but it is certain that maintaining a positive and optimistic attitude and actively cooperating with treatment can maximize the life expectancy of patients.