This is not a happy cactus. Shoot. Have to know anything and everything that you did differently before this occurred. Did you fertilize? If so with what? How much? How often? Did you add any other types of 'FOOD' such as bone meal, fish emulsion? Was this cactus allowed out of doors for a time with the possibility of too cold temperatures? Is this soil potting soil? Potting soil made for cactus? Or is this soil from your garden?
This is an east facing window? How long has this cactus been in this spot? Are you using tap water? How often do you water? How deeply? Do you water so deeply that water fills that saucer? Is there a layer of gravel/rocks/packing peanuts placed beneath the soil and above the drain hole in an effort to improve drainage (NOT a good thing btw).
Allowing this plant's pot to sit in water after watering will definitely compromise the root system with way too much water. Cactus and succulents are mostly killed by overwatering, next would be using garden soil, next would be over fertilization and next would be not enough light.
You might be able to start parts of this cactus in fresh new potting soil but something has happened that looks irreversible. Bummer. Send more information so that we can help you at least learn what went wrong so as not to repeat. Nothing you've done with this plant is too small to mention.
Better picture to be able to see the true colors and more detail.