A superhero is a person with extraordinary powers who use their abilities for the betterment of mankind. Their enemies are often called supervillains.
There are a variety of ways a person can achieve superhuman powers.
Because of the rise in mutants, there are a great deal of people who are born with powers. Powers sometimes develop immediately at birth, but often at puberty.
It is also possible that someone born to superheroes, but not necessarily a mutant, can be born with powers. However, this would qualify them as a mutant.
In their quest to better understand the universe, scientist often make mistakes. Sometimes these mistakes give a person powers. The Fantastic Four were studying cosmic energies. Spider-Man was bitten a spider that just happened to become radioactive. Bruce Banner was bombarded with gamma radiation turning him into the Hulk.
Science on Purpose
Sometimes, a scientist will use their knowledge to create powers for themselves. Tony Stark built himself a set of armor to fight crime as Iron Man. Ant-Man developed Pym Particles to change his size. Captain America was given the Super Soldier Serum to give him extraordinary abilities.
Not all heroes come from Earth. Many come to the planet and abilities normal to them are extraordinary to the locals. Silver Surfer and Nova got the Power Cosmic from Galactus. Thor comes from Asgard where he is the God of Thunder.
Not every superhero necessarily has any extraordinary abilities. Some normal human being choose to help out despite having nothing to compete with more powerful beings. Hawkeye is a highly skilled archer with various trick arrows. Punisher uses various weapons combined with his combat training.
There are a number of reasons one would become a superhero.
Many become heroes simply because they feel it is their moral obligation to use their powers to help others.
Sometimes, a person makes mistakes. They then use their powers to try to make up for that mistake. Spider-Man let a burglar go who then killed his Uncle Ben. Tony Stark led a reckless, self-centered life until he was captured, and uses his technology to prevent further atrocities.
Often, a hero is trying to attain a higher goal and being a hero helps that mission. The X-Men fight for mutant-human equality. Blade is trying to stop vampires. Bishop is trying to stop various dystopian futures. Captain America was trying to stop World War II.
There are a number of people who do heroic deeds through not-so-heroic means. These are known as anti-heroes. They often come into conflict with other superheroes who object to their methods. Punisher saves people but is known for excessive actions against others. Blade will kill any vampire without even trying to save them.
In various alternate universes, people make different decisions and the world turns out differently. Heroes sometimes become villains and villains sometimes become heroes. In the Age of Apocalypse, Magneto actually started the X-Men and fights for mutant equality. Meanwhile in one universe, Spider-Man is actually a villain as Spider-Carnage.