A faraway planet known for its dire weather also whiffs of rotten eggs, according to a new study.

Scientists studied the atmosphere of HD 189733 b, which has scorching temperatures and precipitation akin to raining glass, using data from the James Webb Space Telescope.

Hydrogen sulphide, which also exists on Jupiter, makes up most of HD 189733 b's atmosphere, and emits a bit of a pong, according to researchers. The gas is also emitted during farts.

Finding it here is one of the first detections of hydrogen sulphide on an exoplanet - or planet outside of our solar system.

"So, if your nose could work at 1000C ... the atmosphere would smell like rotten eggs," said Dr Guangwei Fu, an astrophysicist at Johns Hopkins who led the research.