It is theoretically possible if it is closely related enough. Our closest living relatives are the bonobo and chimpanzee. The next closest relatives are the gorilla and the orangutan. In general, different species do not recognize each other as potential mates because each species is uniquely adapted to a different environment. Mixing genes therefore makes the hybrid less well adapted to the environment of either parent species, As a result, it will likely be unable to survive. That is why billions of years of evolution has resulted in almost all species avoiding interbreeding with a different species and being careful to figure out if the individuals they meet are the same species or not before courtship and mating even begins. Even animals that release sperms and eggs into the ocean have ways to avoid fertilization by the wrong species..
Different birds for example sing different songs and/or perform different mating dances and only birds that perform the appropriate song and dance are recognized as suitable mates. Insects often use different phermones or mating calls. The same is true of frogs. Even though many of them may be calling at the same time, females will only approach the males of the same species for mating. Accidents do happen of course, and occasionally hybridization does occur.
Human in general are sexually aroused only by other humans. We simply do not find our ape relatives attractive. This is our way of avoiding interbreeding with a different species. Besides, apes in the wild avoid contact with humans because some humans have actually been hunting them for food. In fact, the AIDS virus was passed along from chimps to humans because the hunters may have been injured or otherwise come into contact with the body fluids of infected chimps, and their AIDS virus infected some of us probably through an open wound. We almost certainly did not get the virus by having sex with chimps. The reluctance to mate is known as pre-mating reproductive isolation.
When different species refuse to mate with other species, they go on different evolutionary paths, and they become less and less similar after they last shared an ancestor. The dissimilar genes they evolve will later make it difficult for them to hybridize. Even if they mate, they may not be able to produce viable young as a result. Scientists call this sort of barrier post-mating reproductive isolation. We do know that humans and apes have pre-mating reproductive isolation. What we do not know for sure is whether there is post-mating reproductive isolation.
Can humans and apes have hybrids? It remains unknown. A Soviet era scientist performed a few crudely designed experiments but he was unable to get a female chimp pregnant through artificial insemination,. Therefore we do not know for sure whether it is possible or if post-mating isolation exists. The Soviet government found out about his experiments and imprisoned him. He died in prison later and no known experiments have since been performed because of legal and ethical concerns. No one knows if hybridization between human and ape is possible and a scientist who performs such an experiment may likely be condemned or prosecuted. There are scientists who are dead certain that humans interbred with Neanderthals, our closest relative, but even that claim has not been verified because there is no irrefutable evidence in the form of Y chromosome or mitochondrial DNA evidence to support that claim. Therefore even the claim that we interbred successfully with another species of humans have not been confirmed.