A hypothesis is an explanation for a phenomenon that can be tested in some way that ideally either proves or disproves it. For the duration of testing, the hypothesis is taken to be true, and the goal of the researcher is to rigorously test its terms. The concept is a very important part of the scientific method, and it also holds true in other disciplines as well. For example, some historians have put forward the hypothesis that the Salem Witch Trials were brought about by the consumption of grains contaminated with ergot, resulting in a mass hysteria.
When someone formulates a hypothesis, he or she does so with the intention of testing it, and he or she should not know the outcome of potential tests before the hypothesis is made. When formulating a hypothesis, the ideals of the scientific method are often kept in mind, so it is designed to be testable in a way that could be replicated by other people. It is also kept clear and simple, and the hypothesis relies on known information and reasoning.
A hypothesis does not have to be right or wrong, but the person formulating it does have to be prepared to test the theory to its limits. If someone hypothesizes that exposure to X causes Y in lab rats, for example, he or she must see if exposure to other things also causes Y. When scientists publish results which support a hypothesis, they often detail the steps they took to try to disprove it as well as the steps that confirmed it, to make the case that much stronger.
In some instances, a hypothesis turns out to be wrong, and this is considered perfectly acceptable, because it still furthers the cause of science. In the example above, for instance, by showing that exposure to X does not cause Y, a scientist can illustrate that further research on Y is needed. In this example, the fact that the hypothesis is wrong does not necessarily mean that substance X is safe, because substance X could still cause something else.
It is also possible for a hypothesis to turn out to be inconclusive after testing. This can be because a scientist lacks the necessary tools for the testing, suggesting that advanced scientific techniques could be used in the future to test the idea. It can also be the result of not having enough information, or a hypothesis that is simply poorly formed and hard to test.