In their death throes, roughly 97 per cent of all stars become a smouldering stellar zombie called a white dwarf, one of the densest objects in the cosmos. A newly discovered white dwarf is being hailed as the most “extreme” one of these on record, cramming a frightful amount of mass into a surprisingly small package.

Scientists said on Wednesday this highly magnetized and rapidly rotating white dwarf is 35 per cent more massive than our sun yet boasts a petite diameter only a bit larger than Earth’s moon. That means it has the greatest mass and, counterintuitively, littlest size of any known white dwarf, owing to its tremendous density.

Only two other types of objects – black holes and neutron stars – are more compact than white dwarfs.

The way this white dwarf, named ZTF J1901+1458, was born also is unusual. It apparently is the product of a binary star system in which two stars orbit each other. These two stars separately evolved into white dwarfs at the end of their life cycles, then spiraled toward one another and merged into a single entity.

With even a smidgen more combined mass, this merger would have resulted in an immense stellar explosion called a supernova, said Caltech astrophysicist Ilaria Caiazzo, lead author of the study published in the journal Nature. It still might explode at some point in the future, Caiazzo added.

“This white dwarf is really extreme,” Caiazzo said. “We found an object that is really at the limit of how small and heavy a white dwarf could be.”

It is located relatively nearby in our Milky Way galaxy, about 130 light years from Earth. A light year is the distance light travels in a year – about 5.9 trillion miles (9.5 trillion km).

The white dwarf is actually shrinking very gradually, becoming ever more dense. If it does not explode, that could lead to a core collapse transforming it into a neutron star, another type of stellar remnant about the size of a city, typically formed after certain very massive stars go supernova. This would be a previously unrecognized path to neutron star formation.

The white dwarf was spotted by astrophysicist and study co-author Kevin Burdge from Caltech’s Palomar Observatory.

“White dwarfs are the most common form of stellar remnant,” said Burdge, who worked on the study at Caltech and is headed to MIT. “So it’s stunning to see the most extreme outliers among them.”

Its diameter of roughly 2,670 miles (4,300 km) – approximately the distance from Boston to Los Angeles or London to Tehran – slightly exceeds the moon’s diameter of about 2,160 miles (3,475 km).

While our sun rotates around its axis once every 27 days, this white dwarf does so every seven minutes. Its magnetic field is about a billion times stronger than Earth’s.

Stars with up to eight times the mass of our sun are thought to be destined to end up as a white dwarf. Such stars eventually burn up all of the hydrogen they use as fuel through nuclear fusion. At this point, gravity causes them to collapse and blow off their outer layers in a ‘red giant’ stage, eventually leaving a dense core that is a white dwarf.

White dwarfs initially have high temperatures but gradually cool over time, lacking any new energy source. In roughly 5 billion years, our sun is expected to become a red giant and later a white dwarf.