There are thousands upon thousands (probably) of pseudogenes in humans. Most of these are thought to be retroviral in origin. At many points during evolution, retroviruses infected humans or human ancestors, got themselves integrated into the genome, and got lucky enough to go germline. This means that it made it to the sperm or eggs. It was propogated by human reproduction.
Some retroviruses do not de-integrate unless conditions turn sour. If conditions never turn sour, the retroviruses accumulate random mutations in their essential genes. Because their genes are never expressed, it is not a loss of fitness to mutate them. After a while, enough of the genes in the previous retrovirus become mutated such that the retrovirus cannot excise itself from the genome. At that point, it becomes a part of the genome padding.
Anyway, there are literally thousands of retrovirally derived sequences in the human genome. Only one retrovirally derived gene is expressed with a function in humans to the best of my knowledge. This is the gene syncytin, involved in placental morphogenesis, which was the env gene from the human endogenous retrovirus HERV-W.