If you are really worried, I would take them to an exotic vet. They will be able to tell you for sure if it is a retained eye cap, something like a calcium deposit or a different disorder. They will also be able to give you prescription or normal eye drops for your pet.
If you aren't particularly worried about it, you can try to wait until their next shed and see if it comes off during that shed. A lot of people do that for retained eye caps in snakes. It isn't life threatening if it is a cap, but please note that my experience comes from snakes and it could be different for leopard geckos. If it is still there after the next shed, you should probably take them to a vet.
Make sure to keep your humidity at a correct level, to keep them watered, and keep the temperatures correct. Usually if it is a retained eye cap, it will come off normally
EDIT: yours looks fairly bad. I would err on the side of being safe by taking it to a vet. I'm sure all they'll do is give you some drops and call it good (assuming it is an eye cap issue), but it would be good to have the gecko checked to make sure, considering the severity of the case - and especially if you don't know when the last shed was.