A mastectomy involves the complete removal of the breast tissue, while a lumpectomy, also known as breast-conserving surgery, involves removing only the tumor and a surrounding margin of healthy tissue.